08-12-2001, 07:14 PM
file after a certain date.
ie if date is greater than mm/dd/yyyy
then save with a password and close the file.
can someone help?
08-15-2001, 09:02 AM
You can protect,save & close your file with
ActiveWorkbook.Protect Password:="a", Structure:=True, Windows:=True
Application.SaveWorkspace "C:\my documents\x.wks"
I do not know the best way of setting a 'shutdown-date' . You could try storing a future date on a hidden sheet and then testing this value whenever the sheet was opened. You could use the Workbook_Open() event and the Now() command to test if the sheet can be opened...
if hiddenval >= now() then
.....display closed msg and shutdown
Hope this helps!