Doing operations on all and same controls at a time

    foreach (Control ctrl in this.Controls)
            {
                if (ctrl.GetType().Name == "TextBox")
                {
                    TextBox tb = ctrl as TextBox;
                    tb.Clear();
                }
            }
Ebook Download
View all
FileInfo in C#
Read by 9.7k people
Download Now!
Learn
View all