DelAllText (2)




Sub ClearAllTextBoxes(frmTarget As Form)
For i = 0 To (frmTarget.Controls.Count - 1)
Set ctrlTarget = frmTarget.Controls(i)
'If it's a textbox, clear it

If TypeOf ctrlTarget Is TextBox Then
ctrlTarget.Text = ""
End If
Next i
End Sub

'This clears all the text boxes. You call it by calling

ClearAllTextBoxes FormName










( delalltext2.html )- by Paolo Puglisi - Modifica del 17/12/2023