Message Box for certain records

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi again
And thanks for all the help you have given me in the past.
I have 3 check boxes and I need a message to pop up if check box "Do Not
Solicit" is ticked on certain records.
I have tried Private Sub Form_BeforeUpdate(Cancel As Integer)
If Me.Do_Not_Solicit = "True" Then MsgBox "This client is not to be
contacted" End If but it didn't work
Any help is greatly appreciated.
 
Thanks Larry but that didn't work either I don't know what I'm doing wrong.
Any more thoughts are appreciated. Thanks.
 
Copy the code you're putting into the entire Oncurrent event for the form
and paste it into your next post. Be sure that the name in
me![Do_Not_Solicit ] really is the name of the checkbox, not its caption.

HTH
 
Thanks Larry
My code is below (copied and pasted)

Private Sub Form_Current()
If Me.Do_Not_Solicit = "True" Then
MsgBox "This client is not to be contacted"
End If
End Sub

Kez



Larry Daugherty said:
Copy the code you're putting into the entire Oncurrent event for the form
and paste it into your next post. Be sure that the name in
me![Do_Not_Solicit ] really is the name of the checkbox, not its caption.

HTH
--
-Larry-
--

Kez said:
Thanks Larry but that didn't work either I don't know what I'm doing wrong.
Any more thoughts are appreciated. Thanks.
 
Change "True" to True and it should work

HTH
--
-Larry-
--

Kez said:
Thanks Larry
My code is below (copied and pasted)

Private Sub Form_Current()
If Me.Do_Not_Solicit = "True" Then
MsgBox "This client is not to be contacted"
End If
End Sub

Kez



Larry Daugherty said:
Copy the code you're putting into the entire Oncurrent event for the form
and paste it into your next post. Be sure that the name in
me![Do_Not_Solicit ] really is the name of the checkbox, not its caption.

HTH
--
-Larry-
--

Kez said:
Thanks Larry but that didn't work either I don't know what I'm doing wrong.
Any more thoughts are appreciated. Thanks.

:

Hi,

try putting your code in the OnCurrent event.

HTH
--
-Larry-
--

Hi again
And thanks for all the help you have given me in the past.
I have 3 check boxes and I need a message to pop up if check box
"Do
Not
Solicit" is ticked on certain records.
I have tried Private Sub Form_BeforeUpdate(Cancel As Integer)
If Me.Do_Not_Solicit = "True" Then MsgBox "This client is not to be
contacted" End If but it didn't work
Any help is greatly appreciated.
 
Larry you are a GENIUS (not to mention a lifesaver)
Many thanks again for taking the time to help me.

Kez

Larry Daugherty said:
Change "True" to True and it should work

HTH
--
-Larry-
--

Kez said:
Thanks Larry
My code is below (copied and pasted)

Private Sub Form_Current()
If Me.Do_Not_Solicit = "True" Then
MsgBox "This client is not to be contacted"
End If
End Sub

Kez



Larry Daugherty said:
Copy the code you're putting into the entire Oncurrent event for the form
and paste it into your next post. Be sure that the name in
me![Do_Not_Solicit ] really is the name of the checkbox, not its caption.

HTH
--
-Larry-
--

Thanks Larry but that didn't work either I don't know what I'm doing
wrong.
Any more thoughts are appreciated. Thanks.

:

Hi,

try putting your code in the OnCurrent event.

HTH
--
-Larry-
--

Hi again
And thanks for all the help you have given me in the past.
I have 3 check boxes and I need a message to pop up if check box "Do
Not
Solicit" is ticked on certain records.
I have tried Private Sub Form_BeforeUpdate(Cancel As Integer)
If Me.Do_Not_Solicit = "True" Then MsgBox "This client is not to be
contacted" End If but it didn't work
Any help is greatly appreciated.
 
Back
Top