469,912 Members | 1,727 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,912 developers. It's quick & easy.

Flash MX: Date conversion from String to Date

108 100+

I'm using MDMZinc to insert/update records into an MSAccess database, many headaches have been caused by dates.

Apparently the best method to avoid complication is to record date stamp as a numeric value, which i have done using the flash getTime() function (see below):-

Expand|Select|Wrap|Line Numbers
  1. var my_date:Date = new Date();
  2. var quiznumberdate = my_date.getTime();
  4. mdm.Database.MSAccess.runQuery("INSERT INTO UserOverallResults (UserName, QuizTitle, QuizDate) VALUES ('"+UserName+"', '"+title+"', "+quiznumberdate+") "); 
This works fine and later updates where I require date/time comparison all functionh perfectly rather than get confused as they dont know if the date is dd/mm/yyyy or mm/dd/yyyy.

I'm a UK resident and want to retrieve this number out of the database (its stored as a string in the database, god knows why but I couldnt get it to store as numeric) and display it as a date again.

Is this possible? Can anyone please help?

Rob W
Apr 1 '08 #1
0 2800

Post your reply

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

Similar topics

3 posts views Thread by praba kar | last post: by
10 posts views Thread by melissa.nava | last post: by
10 posts views Thread by =?Utf-8?B?TWlrZQ==?= | last post: by
2 posts views Thread by RN1 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.