Footer, "fixed" date

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

In part of my footer macro, (see below) I need a fixed date
- ie: current date, that does not change when I open the file again
on a different date.
The only time the date should change is when I run the macro again,
at some future time, which I would do after making a change to the form.
Currently I go in every morning and change the date in the macro.
There must be a way to get the current date VALUE only, to accomplish
what I need.


..LeftFooter = "&""Arial,Bold""&8Oct. 26, 2004" & Chr(10) & "JFS"

John F. Scholten
 
hi,
try replacing the date with now() or today()
now() will add time to the the date where today will just
give the date.
regards
Frank
 
Hi
..LeftFooter = "&""Arial,Bold""8 & format(date,"MMM, DD, YYYY") &
Chr(10) & "JFS"
 
Its just ' Date ' which gives you current date.

.LeftFooter = "&""Arial,Bold""" & Date & Chr(10) & "JFS"

(Note the 3 quote marks after Bold above.)

Sharad
 
maybe:

..LeftFooter = "&""Arial,Bold""&8" & format(date,"mmm. dd, yyyy") _
& Chr(10) & "JFS"

I don't usually include that period after the Month abbreviation--but that's
just a personal preference.)
 
The replies already posted will give you the date, however, if i understand
correctly, you don't want that date to change again for that file. one way
is to have the macro run just when you press a button (ie, controlled by
you); another way is to have it 'flag' a particular cell when it runs for
the first time and have this code in an 'if...then' statement, so if the
cell is already flagged, it does not re-run the code within the 'if...then'
(and therefore does not re-insert a new date)

hope that makes sense!

tim
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top