I have a file that is used by another person in their directory. When they
save the file I do various tests on values of certain range named cells and
if all the values are ok then that means the file is basically in good order
and I want a copy. The issue is they sometimes mess up a file and don't
realize it until they have mess it up even more, but it I can get a copy
when all test conditions are ok then I will always have the last good copy
handy. I was hoping to do somethin like this:
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)
If (Here are various tests and if OK) Then
ActiveWorkbook.SaveAs Filename:="F:\Shared\Systems\Book3.xls",
FileFormat:= xlNormal, Password:="mybackup"
Endif
End Sub
And then it would go ahead and save their file in their directory.
Note: I would alwasy like their file saved and only save to my directory if
all the tests are ok. I have tried the above but excel errors totally out
where you get the message. Do you want to send a report to Microsoft?
Is there a way to do what I want?
Thank you for your help.
Steven
Bookmarks