View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.misc
sparx
 
Posts: n/a
Default Save - Yes / No / Cancel


Hello all, I have found some vba that may " Force users to enable
macro's ". A workbook using the vba starts up and asks enable or
disable macro's at startup. If you select disable, all sheets are
hidden except one that says about your macro status. If you select
enable, then the one about your macro status is hidden and all the
other sheets are visable using the very-visable routine. This is a
great idea if you wish somebody to run your file as it makes them run
the file macro's and all works well - this is until you might already
have a before_save routine then the file just loops and loops saying
"overwrite existing file? Y/N". So my question is, when you run this
file, and you enable macro's, edit some pages, then go to close, your
prompt with the SaveAs routine that saves the file - but then you press
the Close and then the macro hides all worksheets and displays the macro
status page but because its done that again says "overwrite existing
file? Y/N" - instead of this box appearing - is there a macro that can
be added to the before_close routine that automatically selects "Yes"
for you and does not give you the option to press No or Cancel. - If
anyone would like the vba then I can add this.


--
sparx
------------------------------------------------------------------------
sparx's Profile: http://www.excelforum.com/member.php...o&userid=16787
View this thread: http://www.excelforum.com/showthread...hreadid=539543