function isNum(t)
{
	var s,i=0;
	s=t.value;
	for(i=0;i<s.length;i++)
	{
		if((s.charAt(i) < "0") || (s.charAt(i) > "9" ))
		{
			alert("Please Fill The  Valid Quantity!!!");
			t.value="";
			t.focus();
			return false;
		}
	}
	return true;
}

function chkVal(t)
{
	var s,i=0;
	s=t.value;
	
	for(i=0;i<s.length;i++)
	{
		if((s.charAt(i) == "'" ) || (s.charAt(i) == ";" ))
		{
			alert("' and ; are invalid characters!!!");
			//s.charAt(i) = " "
			t.value="";
			t.focus();
			return false;
		}
	}
	return true;
}

function moveRef(t,s)
{
	var ref;
	if(t.value=="")
	{
		alert("Please Fill The quantity!!!");
		return false;
	}
	ref=s.value + "&count=" + t.value;
	location.href=ref;
	alert("Item Has Been Added");
}

function DER(t,s,Act,CU)
{
	//alert(t.value + "   " +  s.value + "  " + Act );
	var ref;
	if(t.value=="")
	{
		alert("Please Fill The quantity!!!");
		return false;
	}
	ref="DelEdt.asp?" + s.value + "&count=" + t.value + "&Act=" + Act + "&" + CU;
	location.href=ref;
}


function chkall(form)
{
	if (form.comname.value=="")
	{
		GoAlert(form.comname,"Please input your Company Name");
		return(false);
	}
	if (form.email.value=="")
	{
		GoAlert(form.email,"Please input your E-Mail Address");
		return(false);
	}
	if (form.person.value=="")
	{
		GoAlert(form.person,"Please input Contact Person Name");
		return(false);
	}
	return(true);
}

function Send(form) {
	if(!chkall(form))return false;
	form.submit();
	return;
}

function GoAlert(P, Str) {
	alert(Str);
	P.focus();
	return;
}

function SendDt(form) {
	if(!chkallDt(form))return false;
	form.submit();
	return;
}

function chkallDt(form)
{
	if (form.CompanyNametxt.value=="")
	{
		GoAlert(form.CompanyNametxt,"Please input your Company Name");
		return(false);
	}
	if (form.Addresstxt.value=="")
	{
		GoAlert(form.Addresstxt,"Please input your Address");
		return(false);
	}
	if (form.Citytxt.value=="")
	{
		GoAlert(form.Citytxt,"Please input your City");
		return(false);
	}
	if (form.Statetxt.value=="")
	{
		GoAlert(form.Statetxt,"Please input your state");
		return(false);
	}
	if (form.Countrytxt.value=="")
	{
		GoAlert(form.Countrytxt,"Please input your country");
		return(false);
	}
	if (form.Ziptxt.value=="")
	{
		GoAlert(form.Ziptxt,"Please input your zip");
		return(false);
	}
	if (form.Telephonetxt.value=="")
	{
		GoAlert(form.Telephonetxt,"Please input your telephone no.");
		return(false);
	}

	if (form.Emailtxt.value=="")
	{
		GoAlert(form.Emailtxt,"Please input your E-Mail Address");
		return(false);
	}
	if (form.ContactPersontxt.value=="")
	{
		GoAlert(form.ContactPersontxt,"Please input Contact Person Name");
		return(false);
	}
	return(true);
}

function test()
{ 
	alert("hello");
}

function disable()
{
	if(event.button==2)
	{
	alert("Option Disabled")
	}
}

