function confirmAction(object, status, complex)
{

	if(status != "delete")
	{

	var Current = object.options[object.selectedIndex].text;

	answer = confirm("Are you sure you want to change status of '" + complex+ "' \n\rfrom '" +  status + "' to '" +Current + "'?");
		if(answer)
		{
			
			  window.location.href = object.options[object.selectedIndex].value;

			 return answer;

		
		}
		else
		{
			return answer;
		
		
		}
	
	}else if(status == "delete")
	{
		answer = confirm("are you sure you want to delete " + complex+ "?");
		return answer;
			
	
	
	}
	else if(status =="edit")
	{
		answer = confirm("are you sure you want to edit this field?");
		return answer;
	}
	

}


function confirmOwnerAction(status, complex)
{

	if(status != "delete")
	{


			answer = confirm("Are you sure you want to change status of '" + complex+ "' to " +  status + "?");

			 return answer;
	}
	else if(status == "delete")
	{
		answer = confirm("are you sure you want to delete " + complex+ "?");
		return answer;
			
	
	
	}

}


function confirmUserAction(user, userAction)
{
	if(userAction == "delete")
	{

	answer = confirm("By deleting user '" + user + "', you will also be deleting all corresponding complexes \n\rAre you sure you want to delete '" + user + "'?\n\rThis cannot be undone");
	return answer;
	
	}
	else if(userAction == "login")
	{
	
	answer = confirm("If you choose to login as '" + user + "',\n\ryou will need to login as yourself afterword to conduct any administrative duties.");
	return answer;
	
	
	
	}



}


function highLight(thisRow)
{
	thisRow.oldColor = thisRow.bgColor;
//	thisRow.bgColor = "#FFFFFF";
	thisRow.bgColor = "#93A8A3";


}


function lowLight(thisRow)
{
	thisRow.bgColor = thisRow.oldColor;
	

}

function openWin(URL)
{
	newWindow = window.open(URL, '640x180',
	'toolbar=no,status=no,scrollbars=yes,location=no,menubar=no,directories=no,resizable=yes,width=640,height=140');	
}

function logout(NAME)
{
//adminAction.js
	answer = confirm(NAME + ", are you sure you want to log out?\n\rIf so, you will be directed to SEL Food Sales home-page\nPlease click on one of the google ads at the bottom to help out SEL Food Sales.");
	
	return answer;
	 

}

