function addLogoandUrl(A){var B="ADD_LOGO";window.open("addLogo.screen?&ClientId="+A+"&BIZ_ACTION_MODE="+B,"","scrollbars=yes,resizable=yes,width=700,height=400")}function UpdateLogoandUrl(A){var B="UPDATE_LOGO";window.open("addLogo.screen?&ClientId="+A+"&BIZ_ACTION_MODE="+B,"","scrollbars=yes,resizable=yes,width=700,height=400")}function validateFormDetails(){var B=false;var C="";var A=1;if(isEmptyValue(document.getElementById("companyId").value)){C=C+A+". Company Creation -> Company Code field is Empty\n";A++;B=true}if(isEmptyValue(document.getElementById("companyName").value)){C=C+A+". Company Creation -> Company Name field is Empty\n";A++;B=true}else{if(!isProperName(document.getElementById("companyName").value)){C=C+A+". Company Creation -> Company Name contains Invalid Characters.\n";A++;B=true}}if(document.getElementById("aboutus_url")&&!isProperURL(document.getElementById("aboutus_url").value)){C=C+A+". Company Creation -> About Us URL is Invalid.\n";A++;B=true}if(document.getElementById("contactus_url")&&!isProperURL(document.getElementById("contactus_url").value)){C=C+A+". Company Creation -> Contact Us URL is Invalid.\n";A++;B=true}if(isEmptyValue(document.getElementById("address1").value)){C=C+A+". Location -> Address [1] field is Empty\n";A++;B=true}else{if(!isProperAddress(document.getElementById("address1").value)){C=C+A+". Location -> Address [1] contains  Invalid Characters.\n";A++;B=true}}if(!isProperAddress(document.getElementById("address2").value)){C=C+A+". Location -> Address [2] contains  Invalid Characters.\n";A++;B=true}if(isEmptyValue(document.getElementById("city").value)){C=C+A+". Location -> City field is Empty\n";A++;B=true}else{if(!isProperName(document.getElementById("city").value)){C=C+A+". Location -> City contains Invalid Characters.\n";A++;B=true}}if(isEmptyValue(document.getElementById("state").value)){C=C+A+". Location -> State field is Empty\n";A++;B=true}else{if(!isProperName(document.getElementById("state").value)){C=C+A+". Location -> State contains Invalid Characters.\n";A++;B=true}}if(isEmptyValue(document.getElementById("pincode").value)){C=C+A+". Location -> PinCode field is Empty\n";A++;B=true}else{if(!isProperZipCode(document.getElementById("pincode").value)){C=C+A+". Location -> PinCode contains Invalid Characters.\n";A++;B=true}}if(isEmptyValue(document.getElementById("contactPerson").value)){C=C+A+". Contact Info.-> Contact Person field is Empty\n";A++;B=true}else{if(!isProperName(document.getElementById("contactPerson").value)){C=C+A+". Contact Info.-> Contact Person contains Invalid Characters.\n";A++;B=true}}if(!isCountryCode(document.getElementById("countrycode1").value)){C=C+A+". Contact Info.-> Phone [1] CountryCode is Invalid.\n";A++;B=true}if(!isNumber(document.getElementById("areacode1").value)){C=C+A+". Contact Info.-> Phone [1] AreaCode is Invalid.\n";A++;B=true}if(isEmptyValue(document.getElementById("phone1").value)){C=C+A+". Contact Info.-> Phone [1] PhoneNumber field is Empty\n";A++;B=true}else{if(!isPhoneNumber(document.getElementById("phone1").value)){C=C+A+". Contact Info.-> Phone [1] PhoneNumber is Invalid.\n";A++;B=true}}if(!isCountryCode(document.getElementById("countrycode2").value)){C=C+A+". Contact Info.-> Phone [2] CountryCode is Invalid.\n";A++;B=true}if(!isNumber(document.getElementById("areacode2").value)){C=C+A+". Contact Info.-> Phone [2] AreaCode is Invalid.\n";A++;B=true}if(!isPhoneNumber(document.getElementById("phone2").value)){C=C+A+". Contact Info.-> Phone [2] PhoneNumber is Invalid.\n";A++;B=true}if(!isCountryCode(document.getElementById("mobilecountrycode").value)){C=C+A+". Contact Info.-> Mobile CountryCode is Invalid.\n";A++;B=true}if(!isNumber(document.getElementById("mobile").value)){C=C+A+". Contact Info.-> Mobile PhoneNumber is Invalid.\n";A++;B=true}if(!isPhoneNumber(document.getElementById("fax").value)){C=C+A+". Contact Info.-> Fax Number is Invalid.\n";A++;B=true}if(isEmptyValue(document.getElementById("companyEmail").value)){C=C+A+". Contact Info.-> Company Email field is Empty\n";A++;B=true}else{if(!isProperEmail(document.getElementById("companyEmail").value)){C=C+A+". Contact Info.-> Company Email should be of a valid email format.\n";A++;B=true}}if(!isProperURL(document.getElementById("website").value)){C=C+A+". Contact Info.-> WebSite is Invalid.\n";A++;B=true}if(isEmptyValue(document.getElementById("fName").value)){C=C+A+". User Info.-> First Name field is Empty\n";A++;B=true}else{if(!isProperName(document.getElementById("fName").value)){C=C+A+". User Info.-> First Name contains Invalid Characters.\n";A++;B=true}}if(!isProperName(document.getElementById("mName").value)){C=C+A+". User Info.-> MiddleName contains Invalid Characters.\n";A++;B=true}if(isEmptyValue(document.getElementById("lName").value)){C=C+A+". User Info.-> Last Name field is Empty\n";A++;B=true}else{if(!isProperName(document.getElementById("lName").value)){C=C+A+". User Info.-> Last Name contains Invalid Characters.\n";A++;B=true}}if(isEmptyValue(document.getElementById("userEmail").value)){C=C+A+". User Info.-> User Email field is Empty\n";A++;B=true}else{if(!isProperEmail(document.getElementById("userEmail").value)){C=C+A+". User Info.-> User Email should be of a valid email format.\n";A++;B=true}}if(isEmptyValue(document.getElementById("userId").value)){C=C+A+". Login Info.-> User Id field is Empty\n";A++;B=true}else{if(!isProperEmail(document.getElementById("userId").value)){C=C+A+". Login Info.-> User Id should be of a valid email format.\n";A++;B=true}}if(document.getElementById("password")&&isEmptyValue(document.getElementById("password").value)){C=C+A+". Login Info.-> Password field is Empty\n";A++;B=true}else{if(document.getElementById("password")&&(document.getElementById("password").value).length<6){C=C+A+". Login Info.-> Password should contain atleast 6 characters.\n";A++;B=true}}if(B){C="Please Correct the following Error(s) : \n\n"+C;alert(C)}return !B}function submitRegistrationFrom(){try{if(validateFormDetails()){document.frmlogin.submit()}}catch(A){alert("Error :::"+A)}}function show_text_box(){document.getElementById("url_div").style.visibility="visible";document.getElementById("white_div").style.visibility="visible"}function Hide(){if(document.getElementById("customertype").value!="L"){document.getElementById("url_div").style.visibility="hidden";document.getElementById("white_div").style.visibility="hidden"}}function if_webservice_customer(){if(document.getElementById("customertype").value=="W"){document.getElementById("issubagentallowed").disabled="disabled";document.getElementById("issubagentallowed").value="N"}else{document.getElementById("issubagentallowed").disabled="";document.getElementById("issubagentallowed").value="N"}};