Using a variable to refer to a control

  • Thread starter Thread starter Guest
  • Start date Start date
Dim strControlName As String

strControlName = "txtField1"
MsgBox "The content of " & strControlName & _
" is " & Me.Controls(strControlName)
 
Back
Top