Custom Date Format

K

Kipp Woodard

The format you want is simply "YYYYMMDD".

Where are you going to use it? If it is for a text control on a form, then
set the Format property of the control to yyymmdd, with no quotes.

If you want to format a column of query, then you would do it thus:

Select Format([MyDateColumn], "yyymmdd") From MyTable

In VBA it would be similar:

strFormattedDate = Format(dtMyDateVariable, "yyymmdd")
 
B

Brian T

thanks

Kipp Woodard said:
The format you want is simply "YYYYMMDD".

Where are you going to use it? If it is for a text control on a form, then
set the Format property of the control to yyymmdd, with no quotes.

If you want to format a column of query, then you would do it thus:

Select Format([MyDateColumn], "yyymmdd") From MyTable

In VBA it would be similar:

strFormattedDate = Format(dtMyDateVariable, "yyymmdd")


Brian T said:
How do I create a date format? I need the format to be: YYYYMMDD.

Thanks
 

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

Top