function chk_Email()
{
	a=chk_Email.arguments;
	emailid=chk_Email.arguments
	for(i=0; i<(a.length-1); i=i+2){
	
			var emailid=a[i].value;
			if ((a[i+1]==1) && (a[i].value.length==0))
			{
			  alert("Email Id Must Be Filled");
			  
			  return false;
			}
			else if ((a[i+1]==0) && (a[i].value.length==0))
			{
				return true;
			}
		}
		var at="@"
		var dot="."
		var lat=emailid.indexOf(at)
		var lstr=emailid.length
		var ldot=emailid.indexOf(dot)
		if (emailid.indexOf(at)==-1){
		   alert("Invalid E-mail ID")
		   return false
		}

		if (emailid.indexOf(at)==-1 || emailid.indexOf(at)==0 || emailid.indexOf(at)==lstr){
		   alert("Invalid E-mail ID")
		   return false
		}

		if (emailid.indexOf(dot)==-1 || emailid.indexOf(dot)==0 || emailid.indexOf(dot)==lstr){
		    alert("Invalid E-mail ID")
		    return false
		}

		 if (emailid.indexOf(at,(lat+1))!=-1){
		    alert("Invalid E-mail ID")
		    return false
		 }

		 if (emailid.substring(lat-1,lat)==dot || emailid.substring(lat+1,lat+2)==dot){
		    alert("Invalid E-mail ID")
		    return false
		 }

		 if (emailid.indexOf(dot,(lat+2))==-1){
		    alert("Invalid E-mail ID")
		    return false
		 }
		
		 if (emailid.indexOf(" ")!=-1){
		    alert("Invalid E-mail ID")
		    return false
		 }

 		 return true					
	}
	
function fnSubmit()
{
	var frm=document.frmFeedback;
	if(frm.txtName.value=="")
	{
		alert("Name Should not be Empty");
		frm.txtName.focus();
		return false;
	}
		
	if (chk_Email(frm.txtEmail, 1)==false)
	{
		frm.txtEmail.focus();
		return false;
	}
	
	if(frm.cboMore.options.length > 0)
	{
		var optionlength=frm.cboMore.options.length;
		var more="";
		for (var k=0;k<optionlength;k++)
		{
			if(frm.cboMore.options[k].selected==true)
			{
				if (more=="")
				{
					more = frm.cboMore.options[k].value;
				}
				else
				{
					more = more + ", " + frm.cboMore.options[k].value;
				}	
			}
		}
		frm.hdnMore.value=more;
	}
	
	if(frm.cboSoftware.options.length > 0)
	{
		var optionlength=frm.cboSoftware.options.length;
		var more="";
		for (var k=0; k<optionlength; k++)
		{
			if(frm.cboSoftware.options[k].selected==true)
			{
				if (more=="")
				{
					more = frm.cboSoftware.options[k].value;
				}
				else
				{
					more = more + ", " + frm.cboSoftware.options[k].value
				}	
			}
		}
		frm.hdnSoftware.value=more;
	}
	
	if(frm.cboHear.options.length > 0)
	{
		var optionlength=frm.cboHear.options.length;
		var more="";
		for (var k=0; k<optionlength; k++)
		{
			if(frm.cboHear.options[k].selected==true)
			{
				if (more=="")
				{
					more = frm.cboHear.options[k].value;
				}
				else
				{
					more = more + ", " + frm.cboHear.options[k].value
				}	
			}
		}
		frm.hdnHear.value=more;
	}
}
