| View previous topic :: View next topic |
| Author |
Message |
PC Pete New User

Joined: 06 Aug 2009 Posts: 7 Location: Melbourne, Australia
|
Posted: Sat Oct 10, 2009 12:28 am Post subject: How do I change the date format in the message list? |
|
|
I'd like to change the default US-only MM/DD/YYYY format to my system default format (dd/mm/yyyy), but I can't seem to find any option to do that.
I would prefer if NMP would "assume" my system's default date settings, is this possible currently?
Or am I missing something blindingly obvious? Like my MySQL settings, or something else?  |
|
| Back to top |
|
 |
administrator Developer


Joined: 24 Jul 2004 Posts: 4752 Location: King William, VA
|
Posted: Sat Oct 10, 2009 2:12 am Post subject: |
|
|
As far as I am aware, the dates that are displayed in NMP use the current date/time format specified in Control Panel -> Regional Settings. At least, that's how it works on my system and others I have corresponded with. It has nothing to do with the database you are using. Dates are stored in the database as floats (or real numbers) and converted to date strings on the fly.
Regards |
|
| Back to top |
|
 |
PC Pete New User

Joined: 06 Aug 2009 Posts: 7 Location: Melbourne, Australia
|
Posted: Sat Oct 10, 2009 3:32 am Post subject: |
|
|
I thought that should be the case...
FYI, I'm running Windows 7 x64 RC1 (build 7100) plus all current hotfixes. The Control panel's regional settings are for Australia, timezone is correct, and in all other apps (Outlook, explorer, etc) all the filesystem dates are the correct format. Only NMP seems to be displaying dates incorrectly. Maybe it's not getting a reasonable response from the system date format strings? |
|
| Back to top |
|
 |
administrator Developer


Joined: 24 Jul 2004 Posts: 4752 Location: King William, VA
|
|
| Back to top |
|
 |
PC Pete New User

Joined: 06 Aug 2009 Posts: 7 Location: Melbourne, Australia
|
Posted: Sun Oct 11, 2009 11:17 pm Post subject: |
|
|
Well, there's definitely a problem somewhere between what the W7 date/time format strings are set to and what's being reported. Here are the actual setting displays for the Regional control panel applet and the test application, side by side :
[/img]
So the system short date format is correct, but it's reporting differently in the test app .
I'm sure I must have other apps having the same problem... I just checked and none of my major apps - Premiere Pro 2.0, Audition 3.0, Office 2007, etc - have the same problem, but a couple of minor apps - GTA IV is the only one I've seen - do seem to have the date format issue. Go figure!
Let me know what you need from me to help sort this out. |
|
| Back to top |
|
 |
BZB Expert

Joined: 26 Apr 2005 Posts: 1389
|
Posted: Sun Oct 11, 2009 11:31 pm Post subject: |
|
|
| PC Pete wrote: |
Let me know what you need from me to help sort this out. |
Realistically, you should update your OS. RC1 was superseded by more RCs and now the RTM. Given the weird behaviour, it's worth considering the problem is in what is an outdated beta OS. |
|
| Back to top |
|
 |
PC Pete New User

Joined: 06 Aug 2009 Posts: 7 Location: Melbourne, Australia
|
Posted: Mon Oct 12, 2009 1:16 am Post subject: |
|
|
Unfortunately, RC1 (build 7100) was the only public release candidate. I have to wait until retail release before I can get the latest build (7600). I will be doing that as soon as I possibly can!
In the meantime, I've asked on the W7 public forums for any other instances of incorrect short date format strings.
I develop using Delphi 6 Professional and Turbo Delphi on the same system, and they seem to return the same (correct) short date format strings. But I've only just tried as a simple VCL app, so I might be avoiding the problem myself and not realise it... |
|
| Back to top |
|
 |
administrator Developer


Joined: 24 Jul 2004 Posts: 4752 Location: King William, VA
|
Posted: Mon Oct 12, 2009 1:20 am Post subject: |
|
|
Well, interestingly enough, the test app was built using Delphi 6 Enterprise...
Regards |
|
| Back to top |
|
 |
PC Pete New User

Joined: 06 Aug 2009 Posts: 7 Location: Melbourne, Australia
|
Posted: Mon Oct 12, 2009 2:07 am Post subject: |
|
|
Can you provide the code used for the test app's retrieval of the date format strings? I can't do that as the help system completely fails on W7 and the workarounds (using 3rd party help display applets) aren't that useful for D6's help links... Sorry about this...
[EDIT]
My apologies, I was using the FormatDateTime() function, not the default routines...
When I use DateToStr(now), which is supposed to use the system default short date format, it returns the date incorrectly, as your sample app does. Turbo Delphi also does the same thing.
So I guess it's a bug in the RC code, after all. It will be interesting to see if anyone in the W7 forums has similar issues.
This is one of the more frustrating issues when testing US-designed software (referring to W7, not NMP!) - the vast majority of testers seem to be US-based, and many of the non-US users (like me, unfortunately) tend to use hand-formatted date routines in development code, instead of the (more correct) system default routines... And since I'm not that familiar with using the preferred methods of formatting, it's not easy to figure out where it's going wrong. Bugger. |
|
| Back to top |
|
 |
administrator Developer


Joined: 24 Jul 2004 Posts: 4752 Location: King William, VA
|
Posted: Mon Oct 12, 2009 12:29 pm Post subject: |
|
|
The test app simply places the contents of the system variables into the edit fields:
var ShortDateFormat: string;
var LongDateFormat: string;
var ShortTimeFormat: string;
var LongTimeFormat: string;
As far as I know, these are retrieved from the system when any Delphi app starts. It's possible that there is a bug in the Delphi RTL code that you could debug that is causing the date format to default to US standard.
Regards |
|
| Back to top |
|
 |
administrator Developer


Joined: 24 Jul 2004 Posts: 4752 Location: King William, VA
|
Posted: Mon Oct 12, 2009 12:31 pm Post subject: |
|
|
Also, in regards to the Delphi help; several months after Vista was released, Microsoft released a Vista-compatible help system for the older *.hlp format. I would think that should also work on W7...
Regards |
|
| Back to top |
|
 |
PC Pete New User

Joined: 06 Aug 2009 Posts: 7 Location: Melbourne, Australia
|
Posted: Tue Oct 13, 2009 1:30 am Post subject: |
|
|
Yes, they did... and no, it doesn't install on W7. I've just now moved my D6 development to a WinXP32 system (my gateway PC) just so I can continue to develop in D6. That doesn't help with the date string problem, unfortunately, but at least now I can compile in resources like icons and application titles and versioning info now!
And yes, I've complained bitterly about this help32 SNAFU directly to MS, who are (apparently) terribly sorry but they still can't provide any idea of whether they will include WINHELP32 support in the retail versions of W7, or even if they will provide such support as downloads after the OS is released. I assume MSDN subscribers would know, but not anyone who can't afford the subscription.
Oh, it's good to work with MS as they shed their legacy software support, isn't it?
Sorry, OT there... |
|
| Back to top |
|
 |
|