By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,078 Members | 2,159 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,078 IT Pros & Developers. It's quick & easy.

Retriving date from access database

P: 1
i've encountered a weired problem while retrieving date from access database:
i'm using ASP VBscript\Jscript
the data is stored using the "date()" command on VBscript code by someone else.
when i'm trying to extract the code from the database using Jscript, i get full(unwanted) format(i.e:Day Mon dd 00:00:00 UTC+0000 Year)
BUT when i do the same thing with VBscript- i get the date AS i entered it(i.e: dd/mm/yyyy)
how can i convert the code from full format t short one? for some reason i cant seem to handle the long format- when i do "typeof(extracted)", i get that it's type is object, and extracted.Item is date. "toString" doesn't work for some reason("Object doesn't support this property or method"/"Object expected")
Any help will be appreciated
Sep 30 '07 #1
Share this Question
Share on Google+
1 Reply

Expert 2.5K+
P: 3,405

I just looked this up and found that you are right, jscript has no native formatDateTime function like vbscript. You will either need to write a function yourself for it, or use vbscript.

Oct 1 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.