ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Hope someone can help me (https://www.excelbanter.com/excel-discussion-misc-queries/94180-hope-someone-can-help-me.html)

Jay Blatherwick

Hope someone can help me
 

Hi

I have created what I thought was a template of an invoice - hoping
other people could use it, putting in their amounts etc then save it
but the template wouldn't change for next time but I can still save new
stuff to the template.

I also want the time to update automatically on the template but not
when it is saved by someone - I then want the date to stay on that date
it was saved so we have a record of all the invoices we create but still
also have the template intact.

Hope someon can help me and sorry if I have not made myself too clear.

Jay


--
Jay Blatherwick
------------------------------------------------------------------------
Jay Blatherwick's Profile: http://www.excelforum.com/member.php...o&userid=35458
View this thread: http://www.excelforum.com/showthread...hreadid=552326


Bob Phillips

Hope someone can help me
 
You need to add some VBA to the template


Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As
Boolean)
Worksheets("Sheet1").Range("A1").Value = Format(Now, "dd mmm yyyy
hh:mm:ss")
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


--

HTH

Bob Phillips

(replace xxxx in the email address with gmail if mailing direct)

"Jay Blatherwick"
<Jay.Blatherwick.29gc81_1150389003.1358@excelfor um-nospam.com wrote in
message news:Jay.Blatherwick.29gc81_1150389003.1358@excelf orum-nospam.com...

Hi

I have created what I thought was a template of an invoice - hoping
other people could use it, putting in their amounts etc then save it
but the template wouldn't change for next time but I can still save new
stuff to the template.

I also want the time to update automatically on the template but not
when it is saved by someone - I then want the date to stay on that date
it was saved so we have a record of all the invoices we create but still
also have the template intact.

Hope someon can help me and sorry if I have not made myself too clear.

Jay


--
Jay Blatherwick
------------------------------------------------------------------------
Jay Blatherwick's Profile:

http://www.excelforum.com/member.php...o&userid=35458
View this thread: http://www.excelforum.com/showthread...hreadid=552326





All times are GMT +1. The time now is 11:18 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com