473,705 Members | 6,195 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Change in Short Date format under Hebrew Regional Settings

This is regarding a change in the Short Date format under Hebrew Regional
Settings, that has caused huge problems in our ASP web application. The
change appears to have been introduced sometime before Windows 2000 Service
Pack 4 and has remained through to Windows XP. I am looking for a solution
that doesn't involve rewriting our application (much) and that allows all
our users to keep using Hebrew Regional Settings.

To summarize our problem - we have an ASP-based intranet web application
that is used in our Israel office. Before we installed Windows 2000 SP4 on
our web server and on the client machines in the office, the application ran
perfectly. Dates appeared on the pages and in input textboxes in the correct
dd/mm/yyyy format. Immediately after installing SP4, dates on the pages and
in input textboxes are formatted as yyyy/mm/dd. This is not just a visual
change, it has caused many functions in the application to break.

No change was made in the Control Panel Regional Options on the clients or
server. In fact if you look there, when Hebrew is chosen, the short date
format on the Date tab is set to dd/mm/yyyy.

We have pinned the problem down to residing in the vbShortDate argument with
the VBScript function FormatDateTime. Following the installation of SP4, RTL
control characters are inserted (unicode character 8207) after each date
separator (/) in the date returned.

I am certain that this is a bug with windows, or a badly implemented new
'feature'. Suppose we're working with the date January 20, 2004 and the
serverside ASP code is returning exactly this (unformatted):
20/01/2004 1:00:00
When we format the date using FormatDateTime( datevalue, vbGeneralDate) we
get this (the exact same thing):
20/01/2004 1:00:00
However, when we format the date using FormatDateTime( datevalue,
vbShortDate) we get this:
[Char8207]20/[Char8207]01/[Char8207]2004

This translates to display (inside an input field in internet explorer) to:
2004/01/20, although the date is really being written as the line above,
i.e. [Char8207]20/[Char8207]01/[Char8207]2004. Internet Explorer is writing
the date to the screen correctly, but the control characters that the
formatdatetime function using vbshortdate argument are inserting are
rearranging the display.

The reason this is such a big problem is that other ASP functions that
process dates do not recognise these dates that include the control
characters as valid. If we use the IsDate function on the output of
FormatDateTime( "20/1/2004", vbShortDate) the result is FALSE (because the
control characters exist).

Does anyone know of a permanent solution to this problem that doesn't
involve rewriting our application (much) and that allows all our users to
keep using Hebrew Regional Settings?
Jul 22 '05 #1
1 4843
Have you tried this:

Thread.CurrentT hread.CurrentCu lture = new CultureInfo(103 7);
(1037 is "he-IL")
I put this in my ASP.NET application in each page I show dates.
"Laurence Neville" <la************ *@hotmail.com> wrote in message
news:%2******** ********@TK2MSF TNGP09.phx.gbl. ..
This is regarding a change in the Short Date format under Hebrew Regional
Settings, that has caused huge problems in our ASP web application. The
change appears to have been introduced sometime before Windows 2000 Service Pack 4 and has remained through to Windows XP. I am looking for a solution
that doesn't involve rewriting our application (much) and that allows all
our users to keep using Hebrew Regional Settings.

To summarize our problem - we have an ASP-based intranet web application
that is used in our Israel office. Before we installed Windows 2000 SP4 on
our web server and on the client machines in the office, the application ran perfectly. Dates appeared on the pages and in input textboxes in the correct dd/mm/yyyy format. Immediately after installing SP4, dates on the pages and in input textboxes are formatted as yyyy/mm/dd. This is not just a visual
change, it has caused many functions in the application to break.

No change was made in the Control Panel Regional Options on the clients or
server. In fact if you look there, when Hebrew is chosen, the short date
format on the Date tab is set to dd/mm/yyyy.

We have pinned the problem down to residing in the vbShortDate argument with the VBScript function FormatDateTime. Following the installation of SP4, RTL control characters are inserted (unicode character 8207) after each date
separator (/) in the date returned.

I am certain that this is a bug with windows, or a badly implemented new
'feature'. Suppose we're working with the date January 20, 2004 and the
serverside ASP code is returning exactly this (unformatted):
20/01/2004 1:00:00
When we format the date using FormatDateTime( datevalue, vbGeneralDate) we
get this (the exact same thing):
20/01/2004 1:00:00
However, when we format the date using FormatDateTime( datevalue,
vbShortDate) we get this:
[Char8207]20/[Char8207]01/[Char8207]2004

This translates to display (inside an input field in internet explorer) to: 2004/01/20, although the date is really being written as the line above,
i.e. [Char8207]20/[Char8207]01/[Char8207]2004. Internet Explorer is writing the date to the screen correctly, but the control characters that the
formatdatetime function using vbshortdate argument are inserting are
rearranging the display.

The reason this is such a big problem is that other ASP functions that
process dates do not recognise these dates that include the control
characters as valid. If we use the IsDate function on the output of
FormatDateTime( "20/1/2004", vbShortDate) the result is FALSE (because the
control characters exist).

Does anyone know of a permanent solution to this problem that doesn't
involve rewriting our application (much) and that allows all our users to
keep using Hebrew Regional Settings?

Jul 22 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
3565
by: Miguel Orrego | last post by:
Hi, My asp pages that display data from databases have suddenly changed the date format they display from UK to US, i.e. 11/17/2001 for 17th Nov 2003. I have checked on the win2k sp3 server that they run on, and the date/time zone is GMT UK and also the regional settings are correct for the UK. The server has been patched in the last couple of weeks, but I'm not sure which patches as various engineers have access to it. However, does...
4
19811
by: Jo | last post by:
Is there anyway we can know using JavaScript the Short Date Format used in the Control Panel -> Regional and Language Settings? I know the using the combinations of following we can get the Locale Long Name format toString() toLocaleString() toLocaleDateString()
3
5251
by: Karunakararao | last post by:
Hi All, How can i get the date based on Regional settings . how can i get the date format using C# .NET " The date displayed in the date/time field should be formatted according to the regional settings made at the operating system level. For example, Canada uses a dd/mm/yyyy format while the US uses mm/dd/yyyy. The month and day should be padded with zeros. In other words, use 01/01/2005 rather than 1/1/2005. The date will...
5
3838
by: Ishaan | last post by:
Hi, Is there any way to pick the data format from operating system settings using C#? I am doing an ASP.Net Application. -- Software engineer Petroleum Development Oman
7
12631
by: Fred Flintstone | last post by:
I'm writing a VB.Net windows forms application. This line of code: Personal.EffectiveDate = GridRow2.Cells("New Value").Value.ToString.Trim Fails with this error: Cast from string "8/23/2005" to type 'Date' is not valid. The date being returned is in US English and my system is set for
6
2386
by: ABC | last post by:
Is there any function return the short date format on the regional and Language Options under control panel?
16
11902
by: Mik | last post by:
I apologise if this post seems a little basic, but I am a newbie and have NO access knowledge. I have downloaded the Accounts Ledger from the Microsoft Website. It allows the user to review a report of transactions between a Start & End date. The Tables and forms i believe are UK format "dd/mm/yyyy", However, when I click on "Review Reports" and enter the date as UK "dd/mm/yyyy", it returns nothing.
3
3197
by: Luqman | last post by:
I have deployed my ASP.Net Application on Windows Server 2000, Service Pack 4, when I run my Application and shows today's date with system.date.today.ToShortDateString, it shows in the format m/d/yyyy while in my Regional Settings, I have defined the format as dd/MM/yyyy. If I run the same Application on my Laptop with Windows XP Pro, it displays the correct date format, any idea please ? Best Regards,
5
6550
OuTCasT
by: OuTCasT | last post by:
Hi. I would like to know how to convert the short date format to the long date format for my application without changing the regional settings from short date to long date. ?
0
8768
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9274
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9034
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8979
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7895
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6606
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5933
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
3138
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2083
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.