Hi have this VBA for a MS Access Form, and would like to have 2 custom buttons.
I would like it to have a button saying 'View these Clients' with the action of opening a form, and an 'Ignore' button' just as OK action.
Thanks in advance.
Code:
Private Sub Form_Load()
nRecords = DCount("*", "ClientsNoCleaner")
If nRecords >= 1 Then
MsgBox "You have " & nRecords & " Clients with no Cleaner assigned. Click 'View these Clients' or 'Ignore' below.", vbInformation, "Message"
Text21.Value = "You have " & nRecords & " Clients with NO Cleaner assigned. Click 'View these Clients' below to resolve the problem."
Else
Text21.Value = "All Clients on the database have a cleaner assigned."
End If
cRecords = DCount("*", "CleanersNoClient")
If nRecords >= 1 Then
MsgBox "You have " & cRecords & " Cleaners with no Client assigned. Click 'View these Cleaners' or 'Ignore' below.", vbInformation, "Message"
Text19.Value = "You have " & cRecords & " Cleaners with NO Clients assigned. Click 'View these Cleaners' below to resolve the problem."
Else
Text19.Value = "All Cleaners on the database have a client assigned."
End If
End Sub
I would like it to have a button saying 'View these Clients' with the action of opening a form, and an 'Ignore' button' just as OK action.
Thanks in advance.