[thelist] ASP: Modify FormatDateTime()

darren darren at web-bitch.co.uk
Thu Mar 13 04:14:02 CST 2003


On Thursday, March 13, 2003 at 08:24, Christian Anderson wrote:

CA> Hey everyone,

CA> I'm showing the date of something on my site like:

CA> FormatDateTime(dt,1)

CA> with "dt" being a date value pulled from my database.  Is there a way to
CA> make it show "Thu" instead of "Thursday" and "Mar" instead of "March"?  I'm
CA> working with a tight space, and would like to cut down on the unnecessary
CA> characters.

try using:

   FormatDateTime(dt, 2) ' 2 = vbShortDate

which should use the short date format however it's setup on your
server.  you could also get the date back from the database in the
format that you want.

hth,

darren.



More information about the thelist mailing list