473,385 Members | 1,324 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

WebUIValidation.js and Latvian[lv]

Hello,
I have found a small bug in WebUIValidation.

In a page I use a CompareValidator to check that the user input date in
correct format.

When using Culture Latvian[lv] the date looks like: "2005.12.13." (note the
last dot!). I use .net framework 1.1 and version
"1_1_4322/webuivalidation.js" in my application.

My validation doesn't work in this culture and if you look up
webuivalidation.js and under function: ValidatorConvertsearch and the line:
"else if (dataType == "Date")"
you can se the following regExp:

var yearFirstExp = new RegExp("^\\s*((\\d{4})|(\\d{2}))([-/]|\\.
?)(\\d{1,2})\\4(\\d{1,2})\\s*$");

This regExp can't work with culture Latvia so you have to add "\.*\" and
then you have a correct RegExp:
var yearFirstExp = new RegExp("^\\s*((\\d{4})|(\\d{2}))([-/]|\\.
?)(\\d{1,2})\\4(\\d{1,2})\\.*\\s*$");

It is not recommended to do manual changes in webuivalidtion so I wonder if
anyone have a solution that can help to solve my problem?

Best regards
/ Quazzo

Dec 19 '05 #1
0 1013

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

Similar topics

0
by: George Hester | last post by:
http://support.microsoft.com/?scid=kb;en-us;229690 This is what it should say, <SCRIPT Runat=Server Language=VBScript> Sub SetLCID() Dim strAcceptLanguage Dim strLCID Dim strPos
2
by: eikel | last post by:
Hi I am a newbie c# programmer, I would like to know how to make a function that switches between languages in windows XP/2000. The languages can be set manually in the language bar. Thanks for...
2
by: scar5308 | last post by:
I have been struggling with this problem for over a week and am not much nearer a solution. I am trying to create a multi language site that only requires the content to be added as simple text or...
22
by: Ubi | last post by:
I am looking for a list of countries and nationalities, against the top level domain. es: ..ar ==Argentina ==Argentinian ..al ==Albania ==Albanian etc. etc.
6
by: Ole Nielsby | last post by:
Does C++ have a method of retrieving this? When launching my app, I want to select the appropriate language for ts GUI, based on the user's language setting. The frameworks wxWidgets and...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...

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.