By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
439,971 Members | 1,467 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 439,971 IT Pros & Developers. It's quick & easy.

"You are about to delete one message"

P: 1
hey people, can you help me out here. How do i replace the message that is produced by MS Access when you click the delete record button. The message "You are about to delete one message"
I would like to replace this message with my own, how does the coding of this go by?????

help!!!!!!
Jun 16 '07 #1
Share this Question
Share on Google+
1 Reply


ADezii
Expert 5K+
P: 8,666
hey people, can you help me out here. How do i replace the message that is produced by MS Access when you click the delete record button. The message "You are about to delete one message"
I would like to replace this message with my own, how does the coding of this go by?????

help!!!!!!
  1. In the Click Event of your DELETE Button:
    Expand|Select|Wrap|Line Numbers
    1. DoCmd.SetWarnings False
    2.   DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
    3.   DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
    4. DoCmd.SetWarnings True
  2. In your Form's Delete() Event:
    Expand|Select|Wrap|Line Numbers
    1. Private Sub Form_Delete(Cancel As Integer)
    2. Dim Msg As String, intResponse As Integer
    3.  
    4. Msg = "Are you sure you want to DELETE this Record?"
    5. intResponse = MsgBox(Msg, vbYesNo + vbDefaultButton1 + vbQuestion, "Delete Confirmation")
    6.  
    7. If intResponse = vbYes Then
    8. Else
    9.   Cancel = True
    10. End If
    11. End Sub
Jun 16 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.