General discussion

Locked

rolling number in Word 2002

By adelhier ·
I would like to use the time (HH:MM:SS) and date (mm/dd/yy) add them together to come up with a rolling number that is changing and that there is a very small chance that there could be duplicates.

If some one now the code lay out that would be great or a tool in word I could use.

This conversation is currently closed to new comments.

6 total posts (Page 1 of 1)  
| Thread display: Collapse - | Expand +

All Comments

Collapse -

rolling number in Word 2002

by DKlippert In reply to rolling number in Word 20 ...

As a field in the document:
{TIME \@ "MMddyyhhmmss"}

(Brackets are inserted using Ctrl+F9)

Collapse -

rolling number in Word 2002

by adelhier In reply to rolling number in Word 20 ...

Thank you for the helping this will get my doc out to the work force.

Collapse -

rolling number in Word 2002

Not sure about word but for vb in general date and time it treated as a double precision decimal point number
There's a CDBL function which will convert any numeric value, including dates, into a double.
example
dim rollingnumber as double
rollingnumber = cdbl(now)
Hope this helps
John

Collapse -

rolling number in Word 2002

Forgot to mention
The date is the part of the number to the left of the decimal point and time is the fractional part. Time is represented as a fraction of a day.

Collapse -

rolling number in Word 2002

by adelhier In reply to rolling number in Word 20 ...

Thank you for giveing an answer, but I found that the first person had one that was alittle ez'er to use.

As a field in the document:
{TIME \@ "MMddyyhhmmss"}

(Brackets are inserted using Ctrl+F9)

This is what he gave my.
I will also try your answer also

Collapse -

rolling number in Word 2002

by adelhier In reply to rolling number in Word 20 ...

This question was closed by the author

Back to Web Development Forum
6 total posts (Page 1 of 1)  

Related Discussions

Related Forums