Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Checkbox

Status
Not open for further replies.

reta

Technical User
Dec 23, 2004
51
AU
How am i able to check if a checkbox has been check with VBA coding.
Thanks
Reta
 
Two different ways.
Code:
Private Sub MychkBox_AfterUpdate()
    Select Case Me.MychkBox.Value
    Case -1
        Me.TextBox.Value = "True"
    Case 0
       Me.TextBox.Value = "False"
    End Select
End Sub
Code:
Private Sub MychkBox_AfterUpdate()
    If Me.MychkBox.Value = True Then
      Me.TextBox.Value = "True"
    Else
      Me.TextBox.Value = "False"
    End If
End Sub
hope this helps

________________________________________
Zameer Abdulla
Visit Me
A child may not be able to lift too much.
But it can certainly hold a marriage together
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top