<!--

function formCheck2(formobj){
	// Enter name of mandatory fields
	var fieldRequired = Array("deduct", "incometax","purchasehome","rrsp","resp","reviewed","currentinvestor","invest","nri","tfsa","investmentOptions","mortgage","gli","pli","companyName","insuranceAmount","changeCompanies","lifeInsurance","lastTime","needs","title","firstname","lastname","address","city","province","postal","phone","email","age","relationship","children");
	// Enter field description to appear in the dialog box
	var fieldDescription = Array("were you able to deduct any of the following expenses?","Would you like to?","Are you planning to purchase a home?","Do you invest in RRSPs?","Do you invest in RESPs?","When was the last time you had your financial plan reviewed?","Are you happy with your current investment advisor?","Where do you invest?","Do you have any Non-Registered investments?","Are you familiar with the Tax Free Savings Account (TFSA)?","Would you like to find out more about other options for your investments?","Do you currently have any mortgage insurance?","Are you covered by Group Life Insurance with your employer?","Do you have Private Life Insurance?","Name of Insurance Company","Amount of Insurance","Is there any reason that would prevent you from changing companies?","Are you currently looking to purchase life insurance? ","When did you last have your life insurance needs reviewed?","Would you like to have your current Life Insurance Needs reviewed?","Title","First Name","Last Name","Mailing Address","City","Province","Postal Code","Phone Number","Email","Your Current Age","Relationship Status","Number of Dependent Children");
	// dialog message
	var alertMsg = "Please complete the following fields:\n";
	
	var l_Msg = alertMsg.length;
	
	for (var i = 0; i < fieldRequired.length; i++){
		var obj = formobj.elements[fieldRequired[i]];
		if (obj){
			switch(obj.type){
			case "select-one":
				if (obj.selectedIndex == -1 || obj.options[obj.selectedIndex].text == "" || obj.options[obj.selectedIndex].text == "Select one"){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				break;
			case "select-multiple":
				if (obj.selectedIndex == -1){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				break;
			case "text":
			case "textarea":
				if (obj.value == "" || obj.value == null){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
				break;
			default:
			}
			if (obj.type == undefined){
				var blnchecked = false;
				for (var j = 0; j < obj.length; j++){
					if (obj[j].checked){
						blnchecked = true;
					}
				}
				if (!blnchecked){
					alertMsg += " - " + fieldDescription[i] + "\n";
				}
			}
		}
	}

	if (alertMsg.length == l_Msg){
		return true;
	}else{
		alert(alertMsg);
		return false;
	}
}
// -->