
VBScript Date format- regional settings ?
Thump! Thump! Thump!
(Me bashing head against head for being so thick.)
Oh joy. Oh bliss. Oh koo kalay.
What a winner.
And other assorted superlatives :)))))))))))))))
Aren't the answers to the most frustrating problems always so {*filter*}y simple!
GGGGGGrrrrrrrrr.
I have been trying to find the answer to that one for ever since Option Pack
For NT4 (IIS4) came out in 1997. I suppose that I had become so {*filter*}y
obsessed and frustrated with it that I couldn't see the wood for the trees.
All the users that have specific profiles in HKEY_USERS\ also have profiles
on disk and IUSR/IWAM don't so where else would they get their settings
from.
And I shudder to think about the amount of code that got written to
circumvent the probelm while cursing the '{*filter*}y yanks' for having such a
'{*filter*}y stupid' date format.
By the way Michael, are you single?
Quote:
> Regional settings are per user...
> An ASP running under the IUSR/IWAM_machinename account is not a typical
> "user". In that context, the regional settings are taken from
> HKEY_USERS\.DEFAULT\Control Panel\International
> A real user actually logged on to the server as an interactive user gets
> regional settings from
> HKEY_CURRENT_USER\Control Panel\International
> which is unique to that user and can be changed independently from any
other
> user. The first time a real user logs on the HKCU branch gets its initial
> values from
> HKEY_USERS\.DEFAULT\Control Panel\International
> just like IUSR/IWAM_machinename with the difference being that a real
user's
> regional settings changes are persistent after they log off.
> So the bottom line is, customized the HKEY_USERS\.DEFAULT\Control
> Panel\International branch in the registry and that's what an ASP page
will
> use...
> --
> Michael Harris
> Microsoft.MVP.Scripting
> --
> Please do not email questions - post them to the newsgroup instead.
> --
> > Yes the tab settings do explicitly say dd/mm/yy for short date format.
> > > Just to be doubly sure -- are the date tab settings (w/in the regional
> > > settings control panel item) consistent with the English(UK) regional
> > > settings? IOW, is the short date format expressly noted as dd/mm/yy?
> > (It's
> > > possible to set different detailed date settings and still see the
> > > "English(UK)" regional setting in the primary tab.)
> > > > I'm running some VBscript with ASP which works with dates and an
> > access
> > > > database.
> > > > When I use the code:
> > > > dteYear = Year(#23/09/01#)
> > > > The year is returned as 2023, not 2001 as I expected.
> > > > I thought that VBScript used the local settings for determining
> > local
> > > > settings for time? The code is running on my PWS and regional
> > settings
> > > > for the PC are UK(GMT).
> > > > Anyone got any ideas what is going on, ultimately the data is to be
> > > > pulled from a input box which would be in dd/mm/yy format and I
> > don't
> > > > which to write further code to manipulate it before passing it to
> > the
> > > > year.
> > > > Thanks,
> > > > Scott.
> > > > Sent via Deja.com
> > > > http://www.*-*-*.com/
> > Sent via Deja.com
> > http://www.*-*-*.com/