![]() |
![]() |
|
|||||||
| Excel Questions All Excel/VBA questions - formulas, macros, pivot tables, general help, etc. Please post to this forum in English only. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Join Date: Mar 2002
Location: Sydney/Brisbane , Australia
Posts: 539
|
Good evening guys.
I have an excel program running. What i want is to make it so the user can only use the program... but they can never actually save it. all changes made within the program will actually be saved to a seperate file on the c:. and reopening the excel program will automatically rectify these links. How can i limit all access to saving the program.? TIA |
|
|
|
|
|
#2 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Auckland, New Zealand
Posts: 4,208
|
Quote:
Private Sub Workbook_BeforeClose(Cancel As Boolean) Cancel = True End Sub Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) Cancel = True End Sub Ivan |
|
|
|
|
|
|
#3 |
|
Banned
Join Date: Mar 2002
Posts: 1,582
|
Hi Qroozn
Part 2 of Ivans solution will work, but part one would stop the Workbook from being closed, I'm not sure if you want that. Why not just make the file 'Read-only'? |
|
|
|
|
|
#4 | |
|
MrExcel MVP
Join Date: Feb 2002
Location: Auckland, New Zealand
Posts: 4,208
|
Quote:
Do what dave suggested Save workbook BUT put password in for open as read only. Then place this code in Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean) Dim Pwd Pwd = InputBox("Enter password to save") If Pwd <> "me" Then Cancel = True End Sub Ivan |
|
|
|
|
![]() |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|