LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 54
Default Confirm a choice before Macro

I have a macro attached to a button that will clear all data on a page. I'd
like there to be a confirmation (that's how I know it from javascript) to
preceed the macro. Here's the code thus far:

Sub clearAll()
Range("D3,...M48").ClearContents
End Sub

Is there something I can throw in the macro, before the Range line that will
ask, "Are you sure you want to delete all data?" If yes then fire macro, if
no then end.

Thanks, JSnow
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to confirm the open dialogue box by using macro coding? Eric Excel Worksheet Functions 3 June 13th 07 12:54 PM
Macro to run when validation choice selected JDay01 Excel Discussion (Misc queries) 3 December 20th 06 08:21 PM
Start Macro after user selects a choice from a pick list mathew Excel Discussion (Misc queries) 2 August 17th 06 03:28 PM
Confirm before deleting a worksheet? edeil Excel Discussion (Misc queries) 1 January 28th 06 02:44 AM
Confirm target cell is equal Pat Excel Discussion (Misc queries) 2 December 8th 04 09:35 PM


All times are GMT +1. The time now is 10:45 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"