0 comments Tuesday, July 31, 2007

Hi,
Most of the time we require to validate the control in the client side using javascript.Below are some useful function


For removing blank spaces with regular Expression-----------------------

function trimAll(value)
{
var temp = value;
var obj = /^(\s*)([\W\w]*)(\b\s*$)/;
if (obj.test(temp))
{
temp = temp.replace(obj, '$2');
}
var obj = / +/g;
temp = temp.replace(obj, " ");
if (temp == " ")
{
temp = "";
}
return temp;
}

For Zip code validation US Zip Code------------------------------------------

function isValidZipCode(val)
{
var exp=/(^\d{5}$)(^\d{5}-\d{4}$)/;
var re = new RegExp(exp);
return (val.match(re));
}

For checking Alphanumeric value-----------------------------------
function CheckAlphanumeric (e)
{
var key;
key = e.which ? e.which : e.keyCode;
if((key>=48 &&amp;amp; key<=57)(key>=65 && key<=91) (key >=97 && key<=123)) {
e.returnValue= true;
}
else
{
alert("please enter Alphanumeric only");
e.returnValue = false;
}
}
Time in 12 hour foramt-----------------------------------------------

function validateTime(strValue,state)
{
var objRegExp = /^([1-9]1[0-1]):[0-5]\d(:[0-5]\d(\.\d{1,3})?)?$/;
if(!(objRegExp.test( strValue )))
{
alert("Please Enter "+ state +" time in 12 hour format eg 11:30 ");
}
return objRegExp.test( strValue );
}

Hope this will help all
Regards
Pankaj

0 comments Sunday, July 29, 2007

Hi,
Its really a great news that Visual Studio 2008 Beta 2, .NET FX 3.5 Beta 2 are now available to download.For download click on the below link

http://msdn2.microsoft.com/en-us/vstudio/default.aspx


Regards
Pankaj

0 comments Friday, July 27, 2007

Hi All,

I don’t know how many people notice that developer favorite portal MSDN now in a new look with all extra features which will help user to search new thing and related thing in one page .With tabbed control it will really help user to navigate to the search related download, related community all in one page.
New msdn site also integrated with live search. so all enjoy searching new thing in
www.msdn.com

Regards
Pankaj




0 comments Wednesday, July 11, 2007

Hi,
Windows Live OneCare 2.0 offers the following new features:

· Printer sharing support. Makes it easy to connect printers to local networks so all users in the vicinity can use the same printer.
· Proactive fixes and recommendations. As part of the tune-up process, OneCare also looks at the configuration of the user’s system and makes proactive fixes and recommendations to improve the computing experience.
· Start-time optimizer. Speeds PC boot time by removing rarely used applications from start-up menu.
· Monthly reports. Provides a summary in the Windows Live OneCare dialogue box of key activities and recommended actions for all PCs in a local network.
· Centralized backup. OneCare enables the user to centrally configure and monitor backups for all PCs covered under the same OneCare subscription, with the data from all PCs backed up to a central location.
· Online photo backup. Keeps precious photos safe from theft or accidental loss by backing them up to a secure, offsite location in Windows Live Folders (available at an extra cost)
· Wi-Fi connection security. Makes it easy to secure home WiFi connection and helps protect privacy in wireless data transfers.


click below to download
http://get.live.com/betas/onecare_betas

Regards
Pankaj