Some of the time we need to know what kind ok control are we dealing with. This simple example mimics how to know what is our control.
foreach (Control n in this.Controls) {
String tp = "System.Windows.Forms.TextBox";
if (n.GetType().ToString() ==tp){
// Do something
}
}
Comments