Wierd date format handling in script

I have a user on Win2k, running Notes 6.5.1, multi-user install. The issue below only occurs under one of the user accounts.

The user settings have region set to Australia, so date format is dd/mm/yyyy. All seems to work fine, until script renders it as a string.

I wrote a simple app to demonstrate the issue. Basically, I have a single date field, DateField, that shows a date through a date picker. Format is fine, so I get 27/7/2004.

However, when I use a script button with the following code:

msgbox (uidoc.document.DateField(0))

I see a popup box with 7/27/2004! This causes all sorts of things to break, including the mail template - calendar entries with one-hour duration end up computing end dates years down the track!

Any thoughts?

Subject: Wierd date format handling in script

I found this in the help under Date Statement:

“the operating system’s international Short Date format determines the order in which the numbers are interpreted as month, day, and year values.”

At least it’s a place to start looking.