Unanswered: What is the code to prompt user before action is taken
I have a small bit that I need help with. I am using Excel 2003 and have a small bit of code to Clear out all of my entries on my sheet for me and it works well. However, I would like to actually Prompt the user as to whether or not they are wanting to perform that action BEFORE they wipe out the data on the sheet. Here is what I have to clear it, but not sure how to prompt them and where to place it.
' 8-25-05 by "Bud" to clear all contents
' for new input.
' Keyboard Shortcut: Ctrl+c
If MsgBox("Are you sure?", vbOKCancel, "Question?") = vbOK Then
Hi George and thanks for replying. However, when I click to Clear my entries,
this is what error message I get: See the attached bitmap. Let me know if I placed it on the wrong place and where it should go.