#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 36
Default 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.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default 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.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 36
Default 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.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5,939
Default 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.

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 36
Default 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.

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
Save, save as, page setup dimmed out in unprotected excel sheet? ccKeithJ Excel Discussion (Misc queries) 3 December 14th 07 07:07 PM
Disable save, save as, but allow save via command button TimN Excel Programming 10 September 1st 06 07:05 PM
How to diasble save and save as menu but allow a save button hon123456 Excel Programming 1 June 12th 06 09:50 AM
Totally Disabling (^ save ) (Save as) and Save Icon – Which code do I use: harpscardiff[_10_] Excel Programming 8 November 10th 05 12:24 PM
Save As - Multiple Sheets fails to save as text file Ravee Srinivasan Excel Programming 2 November 10th 03 04:05 PM


All times are GMT +1. The time now is 05:00 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"