<!--

//opens a new popup window containing the page from parameter "url":
var newWin;
function OpenWin(url,title,w,h){
	w=parseInt(w);
	h=parseInt(h);
	if (!mac) if (new String(newWin)!="undefined" && newWin!=null) if (!newWin.closed) newWin.close();
	newWin=window.open(url,title,"width="+w+",height="+h+",top=0,left=0,location=no,directories=no,hotkeys=no,copyhistory=no,resizable=yes,menubar=no,status=no,toolbar=no,scrollbars=yes,z-lock=yes");
	//if (mac) win.resizeTo(w+25,h+50);
	newWin.focus();
}

//opens a new popup window containing the image from parameter:
var newWinImg;
function OpenImage(imgFile){
	if (new String(newWinImg)!="undefined" && newWinImg!=null) if (!newWinImg.closed) newWinImg.close();
	var newWinImg=window.open("","ProjectNewWindowImage","width=100,height=100,top=0,left=0,location=no,directories=no,hotkeys=no,copyhistory=no,resizable=no,menubar=no,status=no,toolbar=no,scrollbars=no,z-lock=yes");
	newWinImg.document.write('<html><head><title>Project :: New Window Image</title></head><body marginwidth="0" marginheight="0" leftmargin="0" topmargin="0" bgcolor="#ffffff" onload="window.resizeTo(parseInt(document.images[\'img\'].width)+10,parseInt(document.images[\'img\'].height)+29)"><img src="' + imgFile + '" name="img" /></body></html>');
	newWinImg.document.close();
	newWinImg.focus();
}

//used for paging:
function GoToPageNo(page){
	document.frmPaging.page.value=page;
	document.frmPaging.submit();
}

//used for paging:
function GoToRecNo(start){
	document.frmMain.start.value=start;
	document.frmMain.submit();
}



//other page functions

function setNullValue (idObj) {
	document.getElementById(idObj).value = "";
}

//functions for left menu

function ChangeDotColor (idObj,colorObj){
	
	leftidlnk="lnk" + leftmenuid;
	if (leftidlnk!=idObj)  {
	document.getElementById(idObj).style.color = colorObj;}
}

function ChangeDotColorSub (idObj,colorObj){
	
	leftidlnk="lnk" + leftmenuid + leftmenusubid;
	if (leftidlnk!=idObj)  {
	document.getElementById(idObj).style.color = colorObj;}
}

function ChangeDotColor1 (idObj,colorObj){
	document.getElementById(idObj).style.color = colorObj;
}

function ShowSub (idObj) {
	document.getElementById(idObj).style.display = "block";
}

function HideSub (idObj) {
	leftsubid = "sub" + leftmenuid;
	if (leftsubid!=idObj) {
	document.getElementById(idObj).style.display = "none";}
}

function ActivateButton (idObj1,idObj2) {
	dot = "dot" + idObj1
	ChangeDotColor1(dot,'FB4E09');
	lnk = "lnk" + idObj1
	ChangeDotColor1(lnk,'FB4E09');
	if (idObj2!=0) {
		subbtn = "sub" + idObj1;
		ShowSub(subbtn);
		subdot = "dot" + idObj1 + idObj2
		ChangeDotColor1(subdot,'B0C72E');
		sublnk = "lnk" + idObj1 + idObj2
		ChangeDotColor1(sublnk,'B0C72E');
	}
}
//-->