Answer the question
In order to leave comments, you need to log in
How to clear all TextBoxes on a form in visual basic 2013?
Good time of the day everyone!
I took the code to clear all TextBoxes on the form
Private Sub Form2_Load(sender As Object, e As EventArgs) Handles MyBase.Load
For I As Integer = 1 To 13
Me.Controls("TextBox" & I).Text = ""
Next
End Sub
Answer the question
In order to leave comments, you need to log in
Maybe someone will come in handy
Dim ss = GroupBox1.Controls ' массив со всеми компонентами гроупбокса
For i = 0 To ss.Count - 1 ' прокручиваем все компоненты по одному
If ss.Item(i).Name.ToString.Substring(0, 4) = "Text" Then ss.Item(i).Text = "" ' свойство компонента text = ""
Next
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question