P
Paul3rd
I have a form w/1 unbound combo box(combo26)
and 13 text boxes. Currently when I open the form
all of the text boxes show values from record #1.
I would like the form to have empty text box fields
until the user makes a selection in the combo26 box.
I've started working on the code as follows:
Private Sub Form_Load()
Dim indx As Integer
With Me.Controls
For indx = 0 To .Count - 1
If Me.Combo26 = Null Then
If (TypeOf Me.Controls(indx) Is TextBox) Then
Me.Controls(indx).Text = Null
ElseIf Me.Combo26 = "*" Then
Me.Controls(indx).Text = Not Null
End If
End If
Next
End With
End Sub
The code compiles OK with no error but it does nothing.
Can someome help?
Thanks in advance,
and 13 text boxes. Currently when I open the form
all of the text boxes show values from record #1.
I would like the form to have empty text box fields
until the user makes a selection in the combo26 box.
I've started working on the code as follows:
Private Sub Form_Load()
Dim indx As Integer
With Me.Controls
For indx = 0 To .Count - 1
If Me.Combo26 = Null Then
If (TypeOf Me.Controls(indx) Is TextBox) Then
Me.Controls(indx).Text = Null
ElseIf Me.Combo26 = "*" Then
Me.Controls(indx).Text = Not Null
End If
End If
Next
End With
End Sub
The code compiles OK with no error but it does nothing.
Can someome help?
Thanks in advance,