![]() |
Prevent from save if...
Hi,
I want to use the ThisWorkBook BeforeSave event to prevent users from saving the sheet if the sheet path is O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" |
Prevent from save if...
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean) If ThisWorkbook.Path = _ "O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" Then Cancel = True End If End Sub -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Pietro" wrote in message ... Hi, I want to use the ThisWorkBook BeforeSave event to prevent users from saving the sheet if the sheet path is O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" |
Prevent from save if...
Hi Bob Phillips
Thank you for your reply... I need exactly to do the following: Once users try to save the sheet that has the below path ,the sheet is automatically saved as "Tier2 Report" on the desktop ,then the sheet is closed and the one saved on the desktop opens automatically "Bob Phillips" wrote: Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) If ThisWorkbook.Path = _ "O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" Then Cancel = True End If End Sub -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Pietro" wrote in message ... Hi, I want to use the ThisWorkBook BeforeSave event to prevent users from saving the sheet if the sheet path is O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" |
Prevent from save if...
Which one on the desktop?
-- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Pietro" wrote in message ... Hi Bob Phillips Thank you for your reply... I need exactly to do the following: Once users try to save the sheet that has the below path ,the sheet is automatically saved as "Tier2 Report" on the desktop ,then the sheet is closed and the one saved on the desktop opens automatically "Bob Phillips" wrote: Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) If ThisWorkbook.Path = _ "O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" Then Cancel = True End If End Sub -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Pietro" wrote in message ... Hi, I want to use the ThisWorkBook BeforeSave event to prevent users from saving the sheet if the sheet path is O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" |
Prevent from save if...
The one that might have been created from a previous transacion by the same code. "Bob Phillips" wrote: Which one on the desktop? -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Pietro" wrote in message ... Hi Bob Phillips Thank you for your reply... I need exactly to do the following: Once users try to save the sheet that has the below path ,the sheet is automatically saved as "Tier2 Report" on the desktop ,then the sheet is closed and the one saved on the desktop opens automatically "Bob Phillips" wrote: Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) If ThisWorkbook.Path = _ "O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" Then Cancel = True End If End Sub -- HTH Bob (there's no email, no snail mail, but somewhere should be gmail in my addy) "Pietro" wrote in message ... Hi, I want to use the ThisWorkBook BeforeSave event to prevent users from saving the sheet if the sheet path is O:\XBOX\XBOX-Tier2\Customer Support\Source\Reports" |
All times are GMT +1. The time now is 04:07 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com