ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Force save as (https://www.excelbanter.com/excel-discussion-misc-queries/1410-force-save.html)


Force save as
 
Is it possible to disable the save button and force a user
to use save as? Making the book read only is not an option
due to some calculation.

Thanks in advance

Frank Kabel

Hi
not sure why read only is not an option for you. You still can perform
changes you just have to save it to a different name

--
Regards
Frank Kabel
Frankfurt, Germany

schrieb im Newsbeitrag
...
Is it possible to disable the save button and force a user
to use save as? Making the book read only is not an option
due to some calculation.

Thanks in advance



Bernie Deitrick

You can use this: of course, you will need to change the file name in the
code... Copy and paste into the ThisWorkbook object's codemodule.

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
If (Not SaveAsUI) And (ThisWorkbook.Name = "Book4.xls") Then
MsgBox "You must use ""Save As"" to save with another name."
Cancel = True
End If
End Sub

HTH,
Bernie
MS Excel MVP

wrote in message
...
Is it possible to disable the save button and force a user
to use save as? Making the book read only is not an option
due to some calculation.

Thanks in advance





I have a count that needs to increment everytime the
workbook is opened. I considered using another workbbok
for the count, but would rather not.

-----Original Message-----
Hi
not sure why read only is not an option for you. You

still can perform
changes you just have to save it to a different name

--
Regards
Frank Kabel
Frankfurt, Germany

schrieb im

Newsbeitrag
...
Is it possible to disable the save button and force a

user
to use save as? Making the book read only is not an

option
due to some calculation.

Thanks in advance


.



All times are GMT +1. The time now is 12:46 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com