function isNumeric(theObject) {
	if (theObject.value == "") { return true; }
	if (theObject == null)     { return true; }
	if (isNaN(theObject.value)) { return true; }
   	return false;
}
function isBlank(theObject) {
	if (theObject.value == "") { return true; }
	if (theObject == null)     { return true; }
}
function isEmail(theObject){
	with(theObject){
		apos=value.indexOf("@");
		dotpos=value.lastIndexOf(".");
		lastpos=value.length-1;
		if (apos<1 || dotpos-apos<2 || lastpos-dotpos>3 || lastpos-dotpos<2){
			if (isNumeric(theObject)){return true}else{return false};
		}
		else{
			return false;
		}
	}
}
function isSelected(theObject){
	for (i=1; i<theObject.length; i++) {
		if (theObject.options[i].selected == 1) { return false; }
	}
	return true;
}
function isChecked(theObject){
    if (theObject.length == null)
    {
        if (theObject.checked)
        {
            return false;
        }
        else
        {
            return true;
        }
    }
    else
    {
	    for (i=0; i<theObject.length; i++) {
		    if (theObject[i].checked == 1) { return false; }
	    }
	}
	return true;
}
function isDateSlash(theObject){
	with(theObject){
		slash1=value.indexOf("/");
		slash2=value.lastIndexOf("/");
		if (slash1!=2 || slash2!=5 || value.length!=10){
			return true;
		}
		else{
			return false;
		}
	}
}
function isLength(theObject, theLength){
	if (theObject.value.length > theLength && theObject.value.length < theLength) { return true; }
	return false;
}
function disableButton(objBtnSubmit, theMessage)
{
	try
	{
		objBtnSubmit = document.getElementById("btnSubmit");
	}
	catch(ex)
	{
		objBtnSubmit = document.subscription.submit;
	}
	try
	{
		objBtnSubmit.disabled = true;
	}
	catch(ex)
	{
		try
		{
			objBtnSubmit.submit.onclick = null;
		}
		catch(ex)
		{

		}
	}
	try
	{
		objBtnSubmit.value = theMessage;
	}
	catch(ex)
	{
	}
}