Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Gunjani
 
Posts: n/a
Default Footer... Entering Serial Nos and incremnting daily


In the footer, is it possible to AUTOmatically place a serial number,
say starting at 00035 on 18 November 2005, each time the date is
changed, daily, the serial number increment by the same number of days.
i.e

19/11/05.... 00036
20/11/05.... 00037
21/11/05.... 00038
22/11/05.... 00039

If it cannot be placed in the Footer is there any otherway?

Thanks for any suggestions.

  #2   Report Post  
Jason Morin
 
Posts: n/a
Default Footer... Entering Serial Nos and incremnting daily

Gunjani-

I would run the 1st macro on the 18th and then place the 2nd macro in the
ThisWorkbook module:

Sub StartFooter()
ActiveSheet.PageSetup.CenterFooter = "00035"
End Sub

Sub Workbook_Open()
Dim iDiff As Integer
Dim sNewNum As String
iDiff = Int(Now) - DateSerial(2005, 11, 18)
sNewNum = CStr(Format(35 + iDiff, "00000"))
ActiveSheet.PageSetup.CenterFooter = sNewNum
End Sub

---
HTH
Jason
Atlanta, GA


"Gunjani" wrote:


In the footer, is it possible to AUTOmatically place a serial number,
say starting at 00035 on 18 November 2005, each time the date is
changed, daily, the serial number increment by the same number of days.
i.e

19/11/05.... 00036
20/11/05.... 00037
21/11/05.... 00038
22/11/05.... 00039

If it cannot be placed in the Footer is there any otherway?

Thanks for any suggestions.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 03:54 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"