function showErrors()
{
	var objErrors = document.getElementById("ctl00_hdnErrors");	
		
	if(objErrors.value != "")
	{ 
		var strErrors = "";		
		
		strErrors = "The Following Errors Occured:\n\n" 
		    + objErrors.value.replace(/_/g, "\n");		
				
		alert(strErrors);		
		
		objErrors.value = "";			
	}		
	
	objErrors = null;
}

function toLowerCase(strControlID)
{
    var objControl = document.getElementById(strControlID)
    
    objControl.value = objControl.value.toLowerCase();
    
    obj = null;
}

function toUpperCase(strControlID)
{
    var objControl = document.getElementById(strControlID)
    
    objControl.value = objControl.value.toUpperCase();
    
    obj = null;
}

function checkAffirmation(strControlID)
{   
    var strAgree = "";
    
    alert(getAffirmationAgreement(strControlID));
        
    if(getAffirmationAgreement(strControlID)) strAgree = "agreeing";   
    else strAgree = "NOT agreeing";
    
    return confirm("You are " + strAgree + " that you have read and will abide by the Requirements for Endourology Fellowship Graduations.\n\nClick OK to confirm, Cancel to abort");
}

function getAffirmationAgreement(strControlID)
{
    var objAffirmation = document.getElementById(strControlID);
    var blnAgreed = false;
    var blnFoundSelection = false;
    
    for(var intRows = 0; intRows < objAffirmation.rows.length; intRows++)
	{					
	    for(var intCells = 0; intCells < objAffirmation.rows[intRows].cells.length; intCells++)
		{						
		    var objRadioButton = objAffirmation.rows[intRows].cells[intCells].childNodes[0];			
			
			if(objRadioButton.checked)
			{
			    if(objRadioButton.value.toLowerCase() == "true") blnAgreed = true;			    
			    blnFoundSelection = true;
			    objRadioButton = null;
			    break;
			}
			
			objRadioButton = null;
		}
			
		if(blnFoundSelection) break;
	}
		
	objAffirmation = null;
	
	return blnAgreed;
}
