我自己想到了,写出来给大家看看:
using System.Reflection;
private void Modify(object which, string property, object newvalue)
{
   Type type = which.GetType();
   PropertyInfo pi = type.GetProperty(property);
   pi.SetValue(which, newvalue, null);
}