function hoverOff()
{
	//border color reference = 'top right bottom left'
	window.event.srcElement.style.borderColor = '#ADBFEF Navy Navy #ADBFEF';
}
function clickOn()
{
	//border color reference = 'top right bottom left'
	window.event.srcElement.style.borderColor = 'Navy #ADBFEF #ADBFEF Navy';
}
function viewDetail(location,elementID,sortedColumnID)
{
	//if there has been a previous row highlighted, we need to set that row back to its original colors
	if (previousRow != "")
	{
		for (i=1; i <= fieldColumns; i++)
		{
			fieldElementID = previousRow + i;
			if ((i == 1) || (i == 2))
			{
				document.getElementById(fieldElementID).style.backgroundColor = previousRowIconColor;
				document.getElementById(fieldElementID).style.color = previousRowFontColor;
			}
			else
			{
				if (i == sortedColumnID)
				{
					document.getElementById(fieldElementID).style.backgroundColor = previousRowSortColor;
					document.getElementById(fieldElementID).style.color = previousRowSortFontColor;
				}
				else
				{
					document.getElementById(fieldElementID).style.backgroundColor = previousRowColor;
					document.getElementById(fieldElementID).style.color = previousRowFontColor;
				}
			}
		}
	}
	//set this row to be the previous row for the next time the row gets clicked
	previousRow = elementID;
	//highlight the selected row
	for (i=1; i <= fieldColumns; i++)
	{
		fieldElementID = elementID + i;
		if ((i == 1) || (i == 2))
		{
			previousRowIconColor = document.getElementById(fieldElementID).style.backgroundColor;
		}
		else
		{
			if (i == sortedColumnID)
			{
				previousRowSortColor = document.getElementById(fieldElementID).style.backgroundColor;
				previousRowSortFontColor = document.getElementById(fieldElementID).style.color;
			}
			else
			{
				previousRowColor = document.getElementById(fieldElementID).style.backgroundColor;
				previousRowFontColor = document.getElementById(fieldElementID).style.color;
			}
		}
		document.getElementById(fieldElementID).style.backgroundColor = 'MidnightBlue';
		document.getElementById(fieldElementID).style.color = '#FFFAB3';
	}
	//set these values to be passed in the form so that when the page is refreshed, the row remains highlighted
	document.frmResult.doHighlight.value = "true";
	document.frmResult.highlightedRowID.value = elementID;
	document.frmResult.sortedColumnID.value = sortedColumnID;
	
	window.open(location,'detail','toolbar=0,location=0,directories=0,status=1,menubar=0,resizeable=1,scrollbars=1,left=10,top=10,width=620,height=480');
	//window.open(location);
}
function tabHover()
{
	window.event.srcElement.className = "clsTabHover"
}
function tabLink()
{
	window.event.srcElement.className = "clsTabLink"
}