ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Save as (https://www.excelbanter.com/excel-programming/388907-save.html)

wildauk

Save as
 
Hi, is there any way I can put a password on save as, I have a work book
other people use and some how they keep saving as by accident, it happens
when they use F5 to go to a sheet, any ideas on the password or how they are
managing to go to save as?

Thank you in advance, Barry.

Jim Thomlinson

Save as
 
The ususal culpret for that is selecting File - Save As , instead of File -
Save. You can add this code to the ThisWorkbook module...

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If SaveAsUI = True Then
If MsgBox("You selected Save As. Is that what you wanted to do?", _
vbYesNo + vbDefaultButton2) = vbNo Then Cancel = True
End If
End Sub
--
HTH...

Jim Thomlinson


"wildauk" wrote:

Hi, is there any way I can put a password on save as, I have a work book
other people use and some how they keep saving as by accident, it happens
when they use F5 to go to a sheet, any ideas on the password or how they are
managing to go to save as?

Thank you in advance, Barry.


wildauk

Save as
 
Sounds perfect, where can I find this work book module.

Barry.

"Jim Thomlinson" wrote:

The ususal culpret for that is selecting File - Save As , instead of File -
Save. You can add this code to the ThisWorkbook module...

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If SaveAsUI = True Then
If MsgBox("You selected Save As. Is that what you wanted to do?", _
vbYesNo + vbDefaultButton2) = vbNo Then Cancel = True
End If
End Sub
--
HTH...

Jim Thomlinson


"wildauk" wrote:

Hi, is there any way I can put a password on save as, I have a work book
other people use and some how they keep saving as by accident, it happens
when they use F5 to go to a sheet, any ideas on the password or how they are
managing to go to save as?

Thank you in advance, Barry.


Jim Thomlinson

Save as
 
The easiest way to get there is to right click the XL icon next to the word
Fle in the XL menu. Select View Code... paste the code from my previous post.
--
HTH...

Jim Thomlinson


"wildauk" wrote:

Sounds perfect, where can I find this work book module.

Barry.

"Jim Thomlinson" wrote:

The ususal culpret for that is selecting File - Save As , instead of File -
Save. You can add this code to the ThisWorkbook module...

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If SaveAsUI = True Then
If MsgBox("You selected Save As. Is that what you wanted to do?", _
vbYesNo + vbDefaultButton2) = vbNo Then Cancel = True
End If
End Sub
--
HTH...

Jim Thomlinson


"wildauk" wrote:

Hi, is there any way I can put a password on save as, I have a work book
other people use and some how they keep saving as by accident, it happens
when they use F5 to go to a sheet, any ideas on the password or how they are
managing to go to save as?

Thank you in advance, Barry.


wildauk

Save as
 
Hi Jim,
I tried it in a blank workbook and it works great.
Thank you,

Barry.

"Jim Thomlinson" wrote:

The easiest way to get there is to right click the XL icon next to the word
Fle in the XL menu. Select View Code... paste the code from my previous post.
--
HTH...

Jim Thomlinson


"wildauk" wrote:

Sounds perfect, where can I find this work book module.

Barry.

"Jim Thomlinson" wrote:

The ususal culpret for that is selecting File - Save As , instead of File -
Save. You can add this code to the ThisWorkbook module...

Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If SaveAsUI = True Then
If MsgBox("You selected Save As. Is that what you wanted to do?", _
vbYesNo + vbDefaultButton2) = vbNo Then Cancel = True
End If
End Sub
--
HTH...

Jim Thomlinson


"wildauk" wrote:

Hi, is there any way I can put a password on save as, I have a work book
other people use and some how they keep saving as by accident, it happens
when they use F5 to go to a sheet, any ideas on the password or how they are
managing to go to save as?

Thank you in advance, Barry.



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

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