This topic is locked

Date Format

3/9/2007 10:36:55 AM
ASPRunner.NET General questions
M
mickj author

I am running ASP Runner Net connected to MS Access DB
One of the fields is "date" and in the DB it is set as Type Date/Time with the format Short Date (e.g. 19/06/1994)
In ASP Runner the field is set as Short Date with the Format DD/MM/YYYY English British
When records are written to the DB, the date format changes to US style, e.g. today = 03/09/2007 rather than 09/03/2007
Server running IIS and PC running ASP Runner both set to UK with correct formatting for United Kingdom
Also, when adding records, the Date Picker appears and displays correctly and in UK format. Also under Advanced Search, the Date Field also displays in the UK format correctly. However when searching, using the Date Picker, if I select 10 March 2007 for a record created on that date, NO RECORD FOUND is returned, but if I enter the date as 3 OCTOBER 2007, the record created on 10/3/2007 is located
Also, if I manually add the date into the "date" field in the DB in the format e.g. 10/03/2007, it displays in the DB correctly and then when I view the record via ASP Runner pages, the date also displays correctly.
It appears to be the way ASP Runner code is writing the date to the DB but with the app' the settings are for United Kingdom or English British were appropriate
Anybody any suggestions as to why this should happen?
Regards

Mick

Eugene 3/12/2007

I checked this on my local box and everything works fine. What framework version and language (c# or vb.net) do you use?

M
mickj author 3/13/2007

I checked this on my local box and everything works fine. What framework version and language (c# or vb.net) do you use?


Hi Eugene,
Using vb.net on Framework 2.0.50727
Regards

Mick
P.S.

As a last resort just tried re-booting the server.

Now all appears to be working OK. Goodness knows why. Must be something going on within IIS but unfortunately no definitive answer. the old Microsoft syndrome - "if all else fails - reboot"

Regards

Mick

Eugene 3/13/2007

I'm happy that you finally managed to fix it!

Y
ykh 11/20/2007

I'm having similar type of problem in the advanced search page. If I select october 20, 2007, the return value of that datefield shows 20/10/2007.
How can I fix this???

Eugene 11/21/2007

Could you please send me your project (including project file, output directory and database backup) on support@xlinesoft.com? I will investigate it on my box.