Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Prompting user before saving

besmart,

Try something lik this in your code.

Dim Msg, Style, Title, Help, Ctxt, Response, MyString
Msg = "Are sure you want to do End of Day ?" ' Define message.
Style = vbYesNo + vbCritical + vbDefaultButton2 ' Define
Response = MsgBox(Msg, Style, Title, Help, Ctxt)
If Response = vbNo Then
Exit Sub
End If

If user chose "Yes" then in your code try,

ActiveWorkbook.Save
ActiveWorkbook.Close


HTH

Charle

--
Message posted from http://www.ExcelForum.com

Reply
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
Prompting user to enable a link Rob Moore Excel Discussion (Misc queries) 0 February 10th 09 03:04 PM
User has intermittent errors while saving. Marcus Excel Discussion (Misc queries) 1 October 6th 07 11:47 AM
User has intermittent errors while saving Marcus Excel Discussion (Misc queries) 2 October 5th 07 12:22 AM
Saving : Changed by another user Jeff Excel Discussion (Misc queries) 0 May 3rd 05 04:24 PM
Saving a Workbook: Forcing User to Rename before Saving Rollin_Again[_6_] Excel Programming 5 April 16th 04 02:54 PM


All times are GMT +1. The time now is 06:33 AM.

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

About Us

"It's about Microsoft Excel"