How can I access the elements from the object obj in this example?
How can I access obj.shapeid and obj.name??? This is just a hypothetical example. In real scenario I call a webservice method with a proxy, which return a object. I want to browse through the object to see the data with in. When I debug in VS, I see the data and child objects within but not sure how to get them programatically ?
Code:
class Shapes
{
int shapeid;
string name;
}
Shapes shape = new Shape();
shape.shapeid = 10;
shape.name = "roger";
object obj = shape;
Comment