C#获取类属性
2021-05-08 15:29
标签:info for reac str foreach nbsp bsp string each C#获取类属性 Type t = fxsinfo.GetType(); C#获取类属性 标签:info for reac str foreach nbsp bsp string each 原文地址:http://www.cnblogs.com/a735882640/p/7625634.html
PropertyInfo[] PropertyList = t.GetProperties();
foreach (PropertyInfo item in PropertyList)
{
string name = item.Name;
object value = item.GetValue(fxsinfo, null);
data.Add(name, value.AsString());
}