Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

date display format

Status
Not open for further replies.

iminore

Programmer
Sep 3, 2002
50
GB
Does anyone know what determines the format of a date (derived from a sql server database) when sent via an asp file to the browser.
It isn't the settings of the receiving pc. I know about 'set dateformat' in sql server - not relevant.
 
do you mean
FormatDateTime(Date[, NamedFormat]) _________________________________________________________
for the best results to your questions: FAQ333-2924
Is your question a most FAQ?? Find out here FAQ333-3048
 
no, suppose I do:

response.write(objRS.fields("datesent"))

I get:

2/6/2003 12:39:00 PM

Is there anyway to display it as dmy, even if I don't know it's a date field, without using any fnuctions. Is there a setting lurking somewhere ?
 
Not sure if I catch the end result you want("even if I don't know if it's a datefield.."). you might try something like in sql:

select MyDate = convert(varchar,datesent,101)
from tableName

this will cause the date to be displayed as

02/03/03

Rich
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top