![]() |
Coupla questions
Hi there,
Q1. When I force run the following code: Sub workbook_before_close() Call Show_Welcome Dim ws As Worksheet For Each ws In ThisWorkbook.Worksheets ws.Visible = (ws.Name < "Welcome") * -1 - 1 Next ws Application.SaveWorkspace End Sub I get a dialogue saying "A file named "Resume.XLW" already exists in the location. Do you want to replace it?" What does this mean, and how would I auto-replace file without user intervention? Q2. What is to stop someone, once macros are enabled to go to Tools|Macro|Macros| then deleting or running whatever they want? Q3. Is there a global routine that will prevent anybody from saving through any method, whether it be a dialogue prompt, the save button in the toolbar, or through File|Save/Save As? Thanks for your time. |
Coupla questions
Hi
try: Sub workbook_before_close() Call Show_Welcome Dim ws As Worksheet For Each ws In ThisWorkbook.Worksheets ws.Visible = (ws.Name < "Welcome") * -1 - 1 Next ws application.displayalerts=false Application.SaveWorkspace application.displayalerts=true End Sub -- Regards Frank Kabel Frankfurt, Germany "Rich" schrieb im Newsbeitrag om... Hi there, Q1. When I force run the following code: Sub workbook_before_close() Call Show_Welcome Dim ws As Worksheet For Each ws In ThisWorkbook.Worksheets ws.Visible = (ws.Name < "Welcome") * -1 - 1 Next ws Application.SaveWorkspace End Sub I get a dialogue saying "A file named "Resume.XLW" already exists in the location. Do you want to replace it?" What does this mean, and how would I auto-replace file without user intervention? Q2. What is to stop someone, once macros are enabled to go to Tools|Macro|Macros| then deleting or running whatever they want? Q3. Is there a global routine that will prevent anybody from saving through any method, whether it be a dialogue prompt, the save button in the toolbar, or through File|Save/Save As? Thanks for your time. |
All times are GMT +1. The time now is 05:14 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com