Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Force File Name Convention
Is there a way to force a user to save a file in a certain format.
For example the only way they would be able to save the file would be as a date in the following format. 12-12-05 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Force File Name Convention
Here is one way that saves it as today's date when closed,
Private Sub Workbook_BeforeClose(Cancel As Boolean) ThisWorkbook.SaveAs Format(Date, "dd-mm-yy") End Sub 'This is workbook event code. 'To input this code, right click on the Excel icon on the worksheet '(or next to the File menu if you maximise your workbooks), 'select View Code from the menu, and paste the code but you probably need to give more details on when you wan t this to happen, what rules determine that date, etc. -- HTH Bob Phillips (remove nothere from email address if mailing direct) "AD108" wrote in message ... Is there a way to force a user to save a file in a certain format. For example the only way they would be able to save the file would be as a date in the following format. 12-12-05 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Force File Name Convention
Thanks alot, looks like a good lead for what I am working on.
"Bob Phillips" wrote in message ... Here is one way that saves it as today's date when closed, Private Sub Workbook_BeforeClose(Cancel As Boolean) ThisWorkbook.SaveAs Format(Date, "dd-mm-yy") End Sub 'This is workbook event code. 'To input this code, right click on the Excel icon on the worksheet '(or next to the File menu if you maximise your workbooks), 'select View Code from the menu, and paste the code but you probably need to give more details on when you wan t this to happen, what rules determine that date, etc. -- HTH Bob Phillips (remove nothere from email address if mailing direct) "AD108" wrote in message ... Is there a way to force a user to save a file in a certain format. For example the only way they would be able to save the file would be as a date in the following format. 12-12-05 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Ghost Links which force Excel to update on File Open | Excel Programming | |||
How do I force an Excel macro to ask me which file and directory? | Excel Discussion (Misc queries) | |||
Force re-open file | Excel Programming | |||
code to force xls file to open after several hours passed | Excel Programming | |||
Force File Read-Only? | Excel Programming |