I have several classes that are going to dump their properties to a "mother ship" class. In trying to accomplish this, I'm using a foreach loop, like this:
------------------------------
public void MoveForward(System.Type t)
{
foreach (PropertyInfo propertyInfo in t.GetProperties())
{
// Set the property with this same name in another class to the value of the property in the class t
}
...
------------------------------
So... Does anybody know how it can be done?
------------------------------
public void MoveForward(System.Type t)
{
foreach (PropertyInfo propertyInfo in t.GetProperties())
{
// Set the property with this same name in another class to the value of the property in the class t
}
...
------------------------------
So... Does anybody know how it can be done?