In this blog I will show you how to explore a given type properties, methods, fields and so forth programmatically. To do so, create a new windows application then add a label, a textbox, a button and a list box into it so that it appears like below:

Figure 1
Then add this code within the button1 event handler scope:
private void button1_Click(object sender, EventArgs e)
{
try
{
Person myPerson = new Person("Bejaoui", "Bechir");
Type myType = Type.GetType(textBox1.Text);
MemberInfo[] r = myType.GetMembers();

Join the conversation! Your thoughts help the community grow.