Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Don
 
Posts: n/a
Default Help with closing down a workbook??

First off....if this turns into a double post, I apologize....I tried to post
this about an hour ago but something messed up and I really don't think it
went through.

Project: I've got a workbook...7 sheets...only one that is available
(easily) to the operator. This operator sees the opening page and clicks on
one of several macro'd buttons....that takes him a data entry sheet and a
data-form opens....when the data is entered, he/she closes the data-form and
the macro prints the page, erases the entered data and returns to the opening
page. I've used an open workbook module to get rid of the tabs, formula
bars, etc, so, unless he/she knows Excel fairly well, it'd be a little
difficult for them to corrupt the programming.

I've also incorporated a before_closing module, which resets the formula
bars, tabs, etc...then closes the program...

Problem: There is no need ever for the operator to save this workbook...but
I found that when it goes into the close routine, the standard window "do you
want to save changes" pops up.....and if you hit cancel at that point the
book stays open and all the formula bars, tabs, etc are now active.

Question: Is there a way to bypass that "save" window?

Thanks in advance and again, if this is double posted, I do apologize,

Have a great day,
  #2   Report Post  
Vasant Nanavati
 
Posts: n/a
Default

Put this code in the ThisWorkbook code module:

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Saved = True
End Sub

--

Vasant



"Don" wrote in message
...
First off....if this turns into a double post, I apologize....I tried to

post
this about an hour ago but something messed up and I really don't think it
went through.

Project: I've got a workbook...7 sheets...only one that is available
(easily) to the operator. This operator sees the opening page and clicks

on
one of several macro'd buttons....that takes him a data entry sheet and a
data-form opens....when the data is entered, he/she closes the data-form

and
the macro prints the page, erases the entered data and returns to the

opening
page. I've used an open workbook module to get rid of the tabs, formula
bars, etc, so, unless he/she knows Excel fairly well, it'd be a little
difficult for them to corrupt the programming.

I've also incorporated a before_closing module, which resets the formula
bars, tabs, etc...then closes the program...

Problem: There is no need ever for the operator to save this

workbook...but
I found that when it goes into the close routine, the standard window "do

you
want to save changes" pops up.....and if you hit cancel at that point the
book stays open and all the formula bars, tabs, etc are now active.

Question: Is there a way to bypass that "save" window?

Thanks in advance and again, if this is double posted, I do apologize,

Have a great day,



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
HOW DO I SUM TWO CELLS FROM ONE WORKBOOK TO ANOTHER WORKBOOK? Bill O'Neal Excel Worksheet Functions 8 August 14th 09 11:36 PM
prohibit closing a workbook Christophero Excel Discussion (Misc queries) 2 April 4th 05 05:54 PM
Unprotect Workbook Kent Excel Discussion (Misc queries) 1 February 4th 05 01:07 AM
make hidden window or workbook visible without specify the name mango Excel Worksheet Functions 1 December 30th 04 03:05 PM
Stubborn toolbars in Excel 007 Excel Discussion (Misc queries) 9 December 11th 04 02:02 PM


All times are GMT +1. The time now is 04:05 PM.

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"