function SetStaticMenu(index)
{
    curVertPos=(document.all)?document.body.scrollTop:window.pageYOffset;
    
	if(menuArray[index].TargetLoc)
	{
	    TLoc=(menuArray[index].Nav4)?menuArray[index].FrstLoc.document.layers[menuArray[index].TargetLoc]:(menuArray[index].DomYes)?menuArray[index].FrstLoc.document.getElementById(menuArray[index].TargetLoc):menuArray[index].FrstLoc.document.all[menuArray[index].TargetLoc];
	    offset=(menuArray[index].Nav4)?TLoc.pageY:TLoc.offsetTop;
	}
	
	if(curVertPos+offset!=menuArray[index].StartTop)
	{   
		menuArray[index].StartTop=curVertPos+offset;
	    menuArray[index].M_StrtTp=curVertPos+offset;
	    var FrstCntnrStyle=(!menuArray[index].Nav4)?menuArray[index].FrstCntnr.style:menuArray[index].FrstCntnr;
	    menuArray[index].PosMenu(menuArray[index].FrstCntnr,menuArray[index].StartTop,menuArray[index].StartLeft);
	}
	setTimeout("menuArray["+index+"].SetStaticMenu("+index+")",100);
}

function BeforeStart(){return}
function AfterBuild(){return}
function BeforeFirstOpen(){return}
function AfterCloseAll(){return}

function Dummy(){return}		// Executes user onload when found

function CnclSlct(){return false}		// Prevents text select on menu items.

function RePos(){			// Repositions menu after resize IE and NS6
	//alert("RePos: " + this.Menu1);
	for(i=0;i<menuArray.length;i++)
	{
	var FrstCntnrStyle=(!menuArray[i].Nav4)?menuArray[i].FrstCntnr.style:menuArray[i].FrstCntnr;
	menuArray[i].FrstWinWdth=(menuArray[i].ExpYes)?menuArray[i].FrstLoc.document.body.clientWidth:menuArray[i].FrstLoc.innerWidth;
	menuArray[i].FrstWinHght=(menuArray[i].ExpYes)?menuArray[i].FrstLoc.document.body.clientHeight:menuArray[i].FrstLoc.innerHeight;
	menuArray[i].ScWinWdth=(menuArray[i].ExpYes)?menuArray[i].ScLoc.document.body.clientWidth:menuArray[i].ScLoc.innerWidth;
	menuArray[i].ScWinHght=(menuArray[i].ExpYes)?menuArray[i].ScLoc.document.body.clientHeight:menuArray[i].ScLoc.innerHeight;
	if(menuArray[i].TargetLoc)menuArray[i].ClcTrgt();
	if(menuArray[i].MenuCentered)menuArray[i].ClcLft();
	if(menuArray[i].MenuVerticalCentered)menuArray[i].ClcTp();
	menuArray[i].PosMenu(menuArray[i].FrstCntnr,menuArray[i].StartTop,menuArray[i].StartLeft)}}

function UnLoaded(){			// Disables menu when document gets unloaded
	//alert("Unloaded: " + menuArray[0].Menu1);
	for(i=0;i<menuArray.length;i++)
	{
	if(typeof(menuArray[i].CloseTmr)!='undefined'&&menuArray[i].CloseTmr)clearTimeout(menuArray[i].CloseTmr);
	menuArray[i].Loadd=0; menuArray[i].Creatd=0;
	if(menuArray[i].HideTop){
	var FCStyle=(menuArray[i].Nav4)?menuArray[i].FrstCntnr:menuArray[i].FrstCntnr.style;
	FCStyle.visibility=menuArray[i].M_Hide
	}
	}}

function ReDoWhole(){		// Reloads after resize NS4 only
    //alert("ReDoWhole: ");
	for(i=0;i<menuArray.length;i++)
	{
	if(menuArray[i].ScWinWdth!=menuArray[i].ScLoc.innerWidth||menuArray[i].ScWinHght!=menuArray[i].ScLoc.innerHeight||menuArray[i].FrstWinWdth!=menuArray[i].FrstLoc.innerWidth||menuArray[i].FrstWinHght!=menuArray[i].FrstLoc.innerHeight)
	
	menuArray[i].Doc.location.reload()}
	}

function Check(WMnu,NoOf){		// Checks menu tree
    //alert("Check: " + this.Menu1)
	var i,Hg,Wd,La,Li,Nof,array,ArrayLoc;
	ArrayLoc=(parent.frames[0])?parent.frames[this.FirstLineFrame]:self;
	for(i=0;i<NoOf;i++){
		array=WMnu+eval(i+1);
		if(!ArrayLoc[array]){this.WbMstrAlrt(1,array); return false}
		La=ArrayLoc[array][0]; Li=ArrayLoc[array][1]; Nof=ArrayLoc[array][3];
		if(i==0){	if(!ArrayLoc[array][4]){this.WbMstrAlrt(2,array); return false}
			if(!ArrayLoc[array][5]){this.WbMstrAlrt(3,array); return false}}
			Hg=ArrayLoc[array][4]; Wd=ArrayLoc[array][5];
		if(!this.WbMstrAlrt(4,'\n\n'+array+'\nwidth: '+Wd+'\nheight: '+Hg+'\nLabel: '+La+'\nLink: '+Li+'\nNo of sub items: '+Nof)){this.WebMasterCheck=0; return true}
		if(ArrayLoc[array][3])if(!this.Check(array+'_',ArrayLoc[array][3])) return false}
	return true}	

function WbMstrAlrt(No,Xtra){
    //alert("WbMstrAlrt: " + this.Menu1);
	if(this.WebMasterCheck)return confirm(this.WbMstrAlrts[No]+Xtra+'   ')}

function Go(){			// Main function
 
   //alert("Go: " + menuArray[0].Menu1);
   for(i=0;i<menuArray.length;i++)
   {
	menuArray[i].Dummy();
	if(menuArray[i].Loadd||!menuArray[i].PosStrt)return;
	menuArray[i].BeforeStart();
	menuArray[i].Creatd=0; menuArray[i].Loadd=1;
	status='Building menu';
	if(menuArray[i].FrstCreat){
		if(menuArray[i].FirstLineFrame =="" || !parent.frames[menuArray[i].FirstLineFrame]){menuArray[i].WbMstrAlrt(0,menuArray[i].FirstLineFrame); menuArray[i].FirstLineFrame=menuArray[i].SecLineFrame}
		if(menuArray[i].FirstLineFrame =="" || !parent.frames[menuArray[i].FirstLineFrame]){menuArray[i].WbMstrAlrt(0,menuArray[i].SecLineFrame); menuArray[i].FirstLineFrame=menuArray[i].SecLineFrame=menuArray[i].DocTargetFrame}
		if(menuArray[i].FirstLineFrame =="" || !parent.frames[menuArray[i].FirstLineFrame]){menuArray[i].WbMstrAlrt(0,menuArray[i].DocTargetFrame); menuArray[i].FirstLineFrame=menuArray[i].SecLineFrame=menuArray[i].DocTargetFrame=''}
		if(menuArray[i].SecLineFrame =="" || !parent.frames[menuArray[i].SecLineFrame])menuArray[i].SecLineFrame=menuArray[i].DocTargetFrame;
		if(menuArray[i].SecLineFrame =="" || !parent.frames[menuArray[i].SecLineFrame])menuArray[i].SecLineFrame=menuArray[i].DocTargetFrame=menuArray[i].FirstLineFrame;
		if(menuArray[i].DocTargetFrame =="" || !parent.frames[menuArray[i].DocTargetFrame])menuArray[i].DocTargetFrame=menuArray[i].SecLineFrame;
		if(menuArray[i].WebMasterCheck){if(!menuArray[i].Check('menuArray['+i+'].Menu',menuArray[i].NoOffFirstLineMenus))return;else menuArray[i].WbMstrAlrt(5,'')}
		menuArray[i].FrstLoc=(menuArray[i].FirstLineFrame!="")?parent.frames[menuArray[i].FirstLineFrame]:window;
		menuArray[i].ScLoc=(menuArray[i].SecLineFrame!="")?parent.frames[menuArray[i].SecLineFrame]:window;
		menuArray[i].DcLoc=(menuArray[i].DocTargetFrame!="")?parent.frames[menuArray[i].DocTargetFrame]:window;
		if (menuArray[i].FrstLoc==menuArray[i].ScLoc) menuArray[i].AcrssFrms=0;
		if (menuArray[i].AcrssFrms)menuArray[i].FirstLineHorizontal=(menuArray[i].MenuFramesVertical)?0:1;
		menuArray[i].FrstWinWdth=(menuArray[i].ExpYes)?menuArray[i].FrstLoc.document.body.clientWidth:menuArray[i].FrstLoc.innerWidth;
		menuArray[i].FrstWinHght=(menuArray[i].ExpYes)?menuArray[i].FrstLoc.document.body.clientHeight:menuArray[i].FrstLoc.innerHeight;
		menuArray[i].ScWinWdth=(menuArray[i].ExpYes)?menuArray[i].ScLoc.document.body.clientWidth:menuArray[i].ScLoc.innerWidth;
		menuArray[i].ScWinHght=(menuArray[i].ExpYes)?menuArray[i].ScLoc.document.body.clientHeight:menuArray[i].ScLoc.innerHeight;
		if(menuArray[i].Nav4){menuArray[i].CntrTxt=(menuArray[i].MenuTextCentered!='left')?"<div align='"+menuArray[i].MenuTextCentered+"'>":"";menuArray[i].TxtClose="</font>"+(menuArray[i].MenuTextCentered!='left')?"</div>":""}}
	menuArray[i].FirstColPos=(menuArray[i].Nav4)?menuArray[i].FrstLoc.document:menuArray[i].FrstLoc.document.body;
	menuArray[i].SecColPos=(menuArray[i].Nav4)?menuArray[i].ScLoc.document:menuArray[i].ScLoc.document.body;
	menuArray[i].DocColPos=(menuArray[i].Nav4)?menuArray[i].DcLoc.document:menuArray[i].ScLoc.document.body;
	if (menuArray[i].TakeOverBgColor)menuArray[i].FirstColPos.bgColor=(menuArray[i].AcrssFrms)?menuArray[i].SecColPos.bgColor:menuArray[i].DocColPos.bgColor;
	if(menuArray[i].FrstCreat){menuArray[i].FrstCntnr=menuArray[i].CreateMenuStructure('menuArray['+i+'].Menu',menuArray[i].NoOffFirstLineMenus);
	menuArray[i].FrstCreat=(menuArray[i].AcrssFrms)?0:1}
	else menuArray[i].CreateMenuStructureAgain('menuArray['+i+'].Menu',menuArray[i].NoOffFirstLineMenus);
		if(menuArray[i].TargetLoc)menuArray[i].ClcTrgt();
		if(menuArray[i].MenuCentered) menuArray[i].ClcLft();
		if(menuArray[i].MenuVerticalCentered) menuArray[i].ClcTp();
	menuArray[i].PosMenu(menuArray[i].FrstCntnr,menuArray[i].StartTop,menuArray[i].StartLeft);
	menuArray[i].IniFlg=1;menuArray[i].Initiate();menuArray[i].Creatd=1; 
	menuArray[i].ScLdAgainWin=(menuArray[i].ExpYes)?menuArray[i].ScLoc.document.body:menuArray[i].ScLoc;
	menuArray[i].ScLdAgainWin.onunload=menuArray[i].UnLoaded;
	//if(menuArray[i].ExpYes)FrstLoc.document.body.onselectstart=CnclSlct;
	menuArray[i].Trigger.onresize=(menuArray[i].Nav4)?menuArray[i].ReDoWhole:menuArray[i].RePos;
	menuArray[i].AfterBuild();
	if(menuArray[i].IsStatic==1)
	{
	    menuArray[i].SetStaticMenu(i);
	}
	}
	status=''}

function ClcTrgt(){			// Calculates StartTop and Left when positioning is relative
	//alert("ClcTrgt: " + this.Menu1);
	var TLoc=(this.Nav4)?this.FrstLoc.document.layers[this.TargetLoc]:(this.DomYes)?this.FrstLoc.document.getElementById(this.TargetLoc):this.FrstLoc.document.all[this.TargetLoc];
	this.StartTop=this.M_StrtTp; this.StartLeft=this.M_StrtLft;
	this.StartTop+=(this.Nav4)?TLoc.pageY:TLoc.offsetTop;
	this.StartLeft+=(this.Nav4)?TLoc.pageX:TLoc.offsetLeft}

function ClcLft(){			// Calculates StartTop and Left when menu is centered
	//alert("ClcLft: " + this.Menu1);
	if(this.MenuCentered!='left'){
		var Size=this.FrstWinWdth-((!this.Nav4)?parseInt(this.FrstCntnr.style.width):this.FrstCntnr.clip.width);
		this.StartLeft=this.M_StrtLft;
		this.StartLeft+=(this.MenuCentered=='right')?Size:Size/2}}

function ClcTp(){			// Calculates StartTop and Left when menu is centered
	//alert("ClcTp: " + this.Menu1);
	if(this.MenuVerticalCentered!='top'){	
		var Size=this.FrstWinHght-((!this.Nav4)?parseInt(this.FrstCntnr.style.height):this.FrstCntnr.clip.height);
		this.StartTop=this.M_StrtTp;
		this.StartTop+=(this.MenuVerticalCentered=='bottom')?Size:Size/2}}

function PosMenu(CntnrPntr,Tp,Lt){	// Positions menu elements
	//alert("PosMenu: " + this.Menu1);
	var Topi,Lefti,Hori;
	var Cntnr=CntnrPntr;
	var Mmbr=Cntnr.FrstMbr;
	var CntnrStyle=(!this.Nav4)?Cntnr.style:Cntnr;
	var MmbrStyle=(!this.Nav4)?Mmbr.style:Mmbr;
	var PadL=(Mmbr.value.indexOf('<')==-1)?this.LftXtra:0;
	var PadT=(Mmbr.value.indexOf('<')==-1)?this.TpXtra:0;
	var MmbrWt=(!this.Nav4)?parseInt(MmbrStyle.width)+PadL:MmbrStyle.clip.width;
	var MmbrHt=(!this.Nav4)?parseInt(MmbrStyle.height)+PadT:MmbrStyle.clip.height;
	var CntnrWt=(!this.Nav4)?parseInt(CntnrStyle.width):CntnrStyle.clip.width;
	var CntnrHt=(!this.Nav4)?parseInt(CntnrStyle.height):CntnrStyle.clip.height;
	var SubTp,SubLt;
	this.RcrsLvl++;
	if (this.RcrsLvl==1 && this.AcrssFrms)(!this.MenuFramesVertical)?Tp=this.FrstWinHght-CntnrHt+((this.Nav4)?4:0):Lt=(this.RightToLeft)?0:this.FrstWinWdth-CntnrWt+((this.Nav4)?4:0);
	if (this.RcrsLvl==2 && this.AcrssFrms)(!this.MenuFramesVertical)?Tp=0:Lt=(this.RightToLeft)?this.ScWinWdth-CntnrWt:0;
	if (this.RcrsLvl==2 && this.AcrssFrms){Tp+=this.VerCorrect;Lt+=this.HorCorrect}
	CntnrStyle.top=(this.RcrsLvl==1)?Tp:0;Cntnr.OrgTop=Tp;
	CntnrStyle.left=(this.RcrsLvl==1)?Lt:0;	Cntnr.OrgLeft=Lt;
	if (this.RcrsLvl==1 && this.FirstLineHorizontal){Hori=1; Lefti=CntnrWt-MmbrWt-2*this.BorderWidth;Topi=0}
	else{Hori=Lefti=0; Topi=CntnrHt-MmbrHt-2*this.BorderWidth}
	while(Mmbr!=null){
		PadL=(Mmbr.value.indexOf('<')==-1)?this.LftXtra:0;
		PadT=(Mmbr.value.indexOf('<')==-1)?this.TpXtra:0;
		MmbrStyle.left=Lefti+this.BorderWidth;
		MmbrStyle.top=Topi+this.BorderWidth;
		if(this.Nav4)Mmbr.CmdLyr.moveTo(Lefti+this.BorderWidth,Topi+this.BorderWidth);
		if(Mmbr.ChildCntnr){
			if(this.RightToLeft)ChldCntnrWdth=(this.Nav4)?Mmbr.ChildCntnr.clip.width:parseInt(Mmbr.ChildCntnr.style.width);
			if(Hori){	SubTp=Topi+MmbrHt+2*this.BorderWidth; 
				SubLt=(this.RightToLeft)?Lefti+MmbrWt-ChldCntnrWdth:Lefti}
			else{	SubLt=(this.RightToLeft)?Lefti-ChldCntnrWdth+this.ChildOverlap*MmbrWt+this.BorderWidth:Lefti+(1-this.ChildOverlap)*MmbrWt+this.BorderWidth; 
				SubTp=(this.RcrsLvl==1&&this.AcrssFrms)?Topi:Topi+this.ChildVerticalOverlap*MmbrHt}
			this.PosMenu(Mmbr.ChildCntnr,SubTp,SubLt)}
			Mmbr=Mmbr.PrvMbr;
		if(Mmbr){	MmbrStyle=(!this.Nav4)?Mmbr.style:Mmbr;
			MmbrWt=(!this.Nav4)?parseInt(MmbrStyle.width)+PadL:MmbrStyle.clip.width;
			MmbrHt=(!this.Nav4)?parseInt(MmbrStyle.height)+PadT:MmbrStyle.clip.height;
			(Hori)?Lefti-=(this.BorderBtwnElmnts)?(MmbrWt+this.BorderWidth):(MmbrWt):Topi-=(this.BorderBtwnElmnts)?(MmbrHt+this.BorderWidth):(MmbrHt)}}
	this.RcrsLvl--}

function Initiate(){			// Resets menu's visiblity
	//alert("Initiate: " + this.Menu1);
	if(this.IniFlg){this.Init(this.FrstCntnr);this.IniFlg=0;if(this.ShwFlg)this.AfterCloseAll();this.ShwFlg=0}}

function Init(CntnrPntr){
    //alert("Init: " + this.Menu1);
	var Mmbr=CntnrPntr.FrstMbr;
	var MCStyle=(this.Nav4)?CntnrPntr:CntnrPntr.style;
	this.RcrsLvl++;
	MCStyle.visibility=(this.RcrsLvl==1)?this.M_Show:this.M_Hide;
	CntnrPntr.Sflg=(this.RcrsLvl==1)?1:0;
	while(Mmbr!=null){
	    
		if(Mmbr.ChildCntnr) this.Init(Mmbr.ChildCntnr);
		Mmbr=Mmbr.PrvMbr}
	this.RcrsLvl--}

function ClearAllChilds(Pntr,ChldPntr){	// Hides no longer wanted elements
	//alert("ClearAllChilds: " + this.Menu1);
	var CPCCStyle;
	while (Pntr){
		if(Pntr.ChildCntnr&&Pntr.ChildCntnr.Sflg){
			CPCCStyle=(this.Nav4)?Pntr.ChildCntnr:Pntr.ChildCntnr.style;
			if(Pntr.ChildCntnr!=ChldPntr){CPCCStyle.visibility=this.M_Hide;Pntr.ChildCntnr.Sflg=0}
			this.ClearAllChilds(Pntr.ChildCntnr.FrstMbr,ChldPntr)}
		Pntr=Pntr.PrvMbr}}	

function GoTo(){			// Triggered by mouse click
	//alert("Goto: " + this.MenuObject.Menu1);
	if(this.LinkTxt){
		status=''; 
		if(this.MenuObject.Nav4){if(this.LowLyr.LoBck)this.LowLyr.bgColor=this.LowLyr.LoBck;if(this.LowLyr.value.indexOf('<img')==-1){this.LowLyr.document.write(this.LowLyr.value);this.LowLyr.document.close()}}
		else{if(this.LoBck)this.style.backgroundColor=this.LoBck; if(this.LwFntClr)this.style.color=this.LwFntClr}
		(this.LinkTxt.indexOf('javascript:')!=-1)?eval(this.LinkTxt):this.MenuObject.DcLoc.location.href=this.LinkTxt}}
		
function OpenMenu(){			// Triggered by mouse over
    //alert("OpenMenu: "+this.MenuObject.Menu1)
	if(!this.MenuObject.Loadd||!this.MenuObject.Creatd) return;
	var TpScrlld=(this.MenuObject.ExpYes)?this.MenuObject.ScLoc.document.body.scrollTop:this.MenuObject.ScLoc.pageYOffset;
	var LScrlld=(this.MenuObject.ExpYes)?this.MenuObject.ScLoc.document.body.scrollLeft:this.MenuObject.ScLoc.pageXOffset;
	var CCnt=(this.MenuObject.Nav4)?this.LowLyr.ChildCntnr:this.ChildCntnr;
	var ThisHt=(this.MenuObject.Nav4)?this.clip.height:parseInt(this.style.height);
	var ThisWt=(this.MenuObject.Nav4)?this.clip.width:parseInt(this.style.width);
	var ThisLft=(this.MenuObject.AcrssFrms&&this.Level==1&&!this.MenuObject.FirstLineHorizontal)?0:(this.MenuObject.Nav4)?this.Container.left:parseInt(this.Container.style.left);
	var ThisTp=(this.MenuObject.AcrssFrms&&this.Level==1&&this.MenuObject.FirstLineHorizontal)?0:(this.MenuObject.Nav4)?this.Container.top:parseInt(this.Container.style.top);
	var CRoll=(this.MenuObject.Nav4)?this.LowLyr.ro:this.ro;
	this.MenuObject.CurrntOvr=this; this.MenuObject.IniFlg=0;
	this.MenuObject.ClearAllChilds(this.Container.FrstMbr,CCnt);
	if(CRoll){	if(this.MenuObject.Nav4)this.LowLyr.document.images[this.LowLyr.rid].src=this.LowLyr.ri2;
		else {var Lc=(this.Level==1)?this.MenuObject.FrstLoc:this.MenuObject.ScLoc;Lc.document.images[this.rid].src=this.ri2}}
	else{	if(this.MenuObject.Nav4){if(this.LowLyr.HiBck)this.LowLyr.bgColor=this.LowLyr.HiBck;if(this.LowLyr.value.indexOf('<img')==-1){this.LowLyr.document.write(this.LowLyr.Ovalue);this.LowLyr.document.close()}}
		else{if(this.HiBck)this.style.backgroundColor=this.HiBck;if(this.HiFntClr)this.style.color=this.HiFntClr}}
	if(CCnt!=null){
		if(!this.MenuObject.ShwFlg){this.MenuObject.ShwFlg=1;this.MenuObject.BeforeFirstOpen()}
		CCnt.Sflg=1;
		var CCW=(this.MenuObject.Nav4)?this.LowLyr.ChildCntnr.clip.width:parseInt(this.ChildCntnr.style.width);
		var CCH=(this.MenuObject.Nav4)?this.LowLyr.ChildCntnr.clip.height:parseInt(this.ChildCntnr.style.height);
		var ChCntTL=(this.MenuObject.Nav4)?this.LowLyr.ChildCntnr:this.ChildCntnr.style;
		var SubLt=(this.MenuObject.AcrssFrms&&this.Level==1)?CCnt.OrgLeft+ThisLft+LScrlld:CCnt.OrgLeft+ThisLft;
		var SubTp=(this.MenuObject.AcrssFrms&&this.Level==1)?CCnt.OrgTop+ThisTp+TpScrlld:CCnt.OrgTop+ThisTp;
		if(this.MenuObject.MenuWrap){
			if(this.MenuObject.RightToLeft){if(SubLt<LScrlld)SubLt=(this.Level==1)?LScrlld:SubLt+(CCW+(1-2*this.MenuObject.ChildOverlap)*ThisWt);
				if(SubLt+CCW>this.MenuObject.ScWinWdth+LScrlld)SubLt=this.MenuObject.ScWinWdth+LScrlld-CCW}
			else{	if(SubLt+CCW>this.MenuObject.ScWinWdth+LScrlld)SubLt=(this.Level==1)?this.MenuObject.ScWinWdth+LScrlld-CCW:SubLt-(CCW+(1-2*this.MenuObject.ChildOverlap)*ThisWt);
				if(SubLt<LScrlld)SubLt=LScrlld}
			if(SubTp+CCH>TpScrlld+this.MenuObject.ScWinHght)SubTp=(this.Level==1)?SubTp=TpScrlld+this.MenuObject.ScWinHght-CCH:SubTp-CCH+(1-2*this.MenuObject.ChildVerticalOverlap)*ThisHt;
			if(SubTp<TpScrlld)SubTp=TpScrlld}
		ChCntTL.top=SubTp;ChCntTL.left=SubLt;ChCntTL.visibility=this.MenuObject.M_Show}
	status=this.LinkTxt}	

function OpenMenuClick(){			// Triggered by mouse over
	//alert("OpenMenuClick: " + this.MenuObject.Menu1);
	if(!this.MenuObject.Loadd||!this.MenuObject.Creatd) return;
	var CCnt=(this.MenuObject.Nav4)?this.LowLyr.ChildCntnr:this.ChildCntnr;
	var CRoll=(this.MenuObject.Nav4)?this.LowLyr.ro:this.ro;
	this.MenuObject.CurrntOvr=this; this.MenuObject.IniFlg=0;
	this.MenuObject.ClearAllChilds(this.Container.FrstMbr,CCnt);
	if(CRoll){	if(this.MenuObject.Nav4)this.LowLyr.document.images[this.LowLyr.rid].src=this.LowLyr.ri2;
		else {var Lc=(this.Level==1)?this.MenuObject.FrstLoc:this.MenuObject.ScLoc;Lc.document.images[this.rid].src=this.ri2}}
	else{	if(this.MenuObject.Nav4){if(this.LowLyr.HiBck)this.LowLyr.bgColor=this.LowLyr.HiBck;if(this.LowLyr.value.indexOf('<img')==-1){this.LowLyr.document.write(this.LowLyr.Ovalue);this.LowLyr.document.close()}}
		else{if(this.HiBck)this.style.backgroundColor=this.HiBck;if(this.HiFntClr)this.style.color=this.HiFntClr}}
	status=this.LinkTxt}	

function CloseMenu(){		// Triggered by mouse out
    //alert("CloseMenu: "+this.MenuObject.Menu1)
	if(!this.MenuObject.Loadd||!this.MenuObject.Creatd) return;
	var CRoll=(this.MenuObject.Nav4)?this.LowLyr.ro:this.ro;
	if(CRoll){	if(this.MenuObject.Nav4)this.LowLyr.document.images[this.LowLyr.rid].src=this.LowLyr.ri1;
		else {var Lc=(this.Level==1)?this.MenuObject.FrstLoc:this.MenuObject.ScLoc;Lc.document.images[this.rid].src=this.ri1}}
	else{	if(this.MenuObject.Nav4){if(this.LowLyr.LoBck)this.LowLyr.bgColor=this.LowLyr.LoBck;if(this.LowLyr.value.indexOf('<img')==-1){this.LowLyr.document.write(this.LowLyr.value);this.LowLyr.document.close()}}
		else{if(this.LoBck)this.style.backgroundColor=this.LoBck;if(this.LwFntClr)this.style.color=this.LwFntClr}}
	status='';
	test=this.MenuObject.CurrntOvr;
	testObject=this.MenuObject;
	if(this==this.MenuObject.CurrntOvr){this.MenuObject.IniFlg=1;if (this.MenuObject.CloseTmr) clearTimeout(this.MenuObject.CloseTmr);this.MenuObject.CloseTmr=setTimeout('testObject.Initiate(test)',this.MenuObject.DissapearDelay)}}

function CntnrSetUp(theObject,Wdth,Hght,NoOff){	// Sets up layer that holds group of elements
	//alert("CntnrSetUp: " + Wdth +this.Menu2);
	var x=(this.RcrsLvl==1)?this.BorderColor:this.BorderSubColor;
	theObject.FrstMbr=null;
	theObject.OrgLeft=theObject.OrgTop=0;
	theObject.Sflg=0;
	if(x)theObject.bgColor=x;
	if(this.Nav4){theObject.visibility='hide';theObject.resizeTo(Wdth,Hght)}
	else{if(x)theObject.style.backgroundColor=x;
		theObject.style.width=Wdth;
		theObject.style.height=Hght;
		theObject.style.fontFamily=this.FontFamily;
		theObject.style.fontWeight=(this.FontBold)?'bold':'normal';
		theObject.style.fontStyle=(this.FontItalic)?'italic':'normal';
		theObject.style.fontSize=this.FontSize+'pt';
		theObject.style.zIndex=this.RcrsLvl+this.Ztop}}

function MbrSetUp(theObject,MmbrCntnr,PrMmbr,WhatMenu,Wdth,Hght){ // Sets up element IE & NS6
	//alert("MbrSetUp: " + this.Menu1);
	var Location=(this.RcrsLvl==1)?this.FrstLoc:this.ScLoc;
	var MemVal=eval(WhatMenu+'[0]');
	var t,T,L,W,H,S;
	var a,b,c,d;
	theObject.MenuObject=this;
	theObject.PrvMbr=PrMmbr;
	theObject.Level=this.RcrsLvl;
	theObject.LinkTxt=eval(WhatMenu+'[1]');
	theObject.Container=MmbrCntnr;
	theObject.ChildCntnr=null;
	theObject.style.overflow='hidden';
	theObject.style.cursor=(this.ExpYes&&(theObject.LinkTxt||(this.RcrsLvl==1&&this.UnfoldsOnClick)))?'hand':'default';
	theObject.ro=0;
	if(MemVal.indexOf('rollover')!=-1){
		theObject.ro=1;theObject.ri1=MemVal.substring(MemVal.indexOf(':')+1,MemVal.lastIndexOf(':'));
		theObject.ri2=MemVal.substring(MemVal.lastIndexOf(':')+1,MemVal.length);
		theObject.rid=WhatMenu+'i';MemVal="<img src='"+theObject.ri1+"' name='"+theObject.rid+"'>"}
	theObject.value=MemVal;
	if(this.RcrsLvl==1){a=this.LowBgColor; b=this.HighBgColor; c=this.FontLowColor; d=this.FontHighColor}
	else {a=this.LowSubBgColor; b=this.HighSubBgColor; c=this.FontSubLowColor; d=this.FontSubHighColor}
	theObject.LoBck=a;
	theObject.LwFntClr=c;
	theObject.HiBck=b;
	theObject.HiFntClr=d; 
	theObject.style.color=theObject.LwFntClr;
	if(theObject.LoBck)theObject.style.backgroundColor=theObject.LoBck;
	theObject.style.textAlign=this.MenuTextCentered;
	if(eval(WhatMenu+'[2]'))theObject.style.backgroundImage="url(\'"+eval(WhatMenu+'[2]')+"\')";
	if(MemVal.indexOf('<')==-1){theObject.style.width=Wdth-this.LftXtra;theObject.style.height=Hght-this.TpXtra;
		theObject.style.paddingLeft=this.LeftPaddng;theObject.style.paddingTop=this.TopPaddng}
	else{	theObject.style.width=Wdth; theObject.style.height=Hght}
	if(MemVal.indexOf('<')==-1&&this.DomYes){t=Location.document.createTextNode(MemVal);theObject.appendChild(t)}
	else theObject.innerHTML=MemVal;
	if(eval(WhatMenu+'[3]')){
		S=(this.RcrsLvl==1&&this.FirstLineHorizontal)?this.ArrowDownSrc:(this.RightToLeft)?this.ArrowOtherSrc:this.ArrowRightSrc;
		W=(this.RcrsLvl==1&&this.FirstLineHorizontal)?10:5;
		H=(this.RcrsLvl==1&&this.FirstLineHorizontal)?5:10;
		T=(this.RcrsLvl==1&&this.FirstLineHorizontal)?Hght-7:Hght/2-5;
		L=(this.RcrsLvl==1&&this.FirstLineHorizontal)?Wdth-12:Wdth-7;
		if(this.DomYes){t=Location.document.createElement('img'); theObject.appendChild(t); t.style.position='absolute'; t.src=S; t.style.width=W; t.style.height=H; t.style.top=T; t.style.left=L}
		else{MemVal+="<div style='position:absolute; top:"+T+"; left:"+L+"; width:"+W+"; height:"+H+";visibility:inherit'><img src='"+S+"'></div>"; theObject.innerHTML=MemVal}}
	if(this.ExpYes){
	
		theObject.onmouseover=(this.RcrsLvl==1&&this.UnfoldsOnClick)?this.OpenMenuClick:this.OpenMenu;
		
		theObject.onmouseout=this.CloseMenu; 
		theObject.onclick=(this.RcrsLvl==1&&this.UnfoldsOnClick&&eval(WhatMenu+'[3]'))?this.OpenMenu:this.GoTo}
	else{
		(this.RcrsLvl==1&&this.UnfoldsOnClick)?theObject.addEventListener('mouseover',this.OpenMenuClick,false):theObject.addEventListener('mouseover',this.OpenMenu,false); 
		theObject.addEventListener('mouseout',this.CloseMenu,false); 
		(this.RcrsLvl==1&&this.UnfoldsOnClick&&eval(WhatMenu+'[3]'))?theObject.addEventListener('click',this.OpenMenu,false):theObject.addEventListener('click',this.GoTo,false)}}

function NavMbrSetUp(menuObject,theObject,MmbrCntnr,PrMmbr,WhatMenu,Wdth,Hght){ // Sets up element IE & NS6
	//alert("NavMbrSetUp: "+menuObject.Menu1);
	var a,b,c,d;
	//theObject.MenuObject=menuObject;
	if(menuObject.RcrsLvl==1){a=menuObject.LowBgColor; b=menuObject.HighBgColor; c=menuObject.FontLowColor; d=menuObject.FontHighColor}
	else {a=menuObject.LowSubBgColor; b=menuObject.HighSubBgColor; c=menuObject.FontSubLowColor; d=menuObject.FontSubHighColor}
	theObject.value=eval(WhatMenu+'[0]');
	theObject.ro=0;
	if(theObject.value.indexOf('rollover')!=-1){
		theObject.ro=1;theObject.ri1=theObject.value.substring(theObject.value.indexOf(':')+1,theObject.value.lastIndexOf(':'));
		theObject.ri2=theObject.value.substring(theObject.value.lastIndexOf(':')+1,theObject.value.length);
		theObject.rid=WhatMenu+'i';theObject.value="<img src='"+theObject.ri1+"' name='"+theObject.rid+"'>"}
	if(menuObject.LeftPaddng&&theObject.value.indexOf('<')==-1&&menuObject.MenuTextCentered=='left')theObject.value='&nbsp\;'+theObject.value;
	if(menuObject.FontBold)theObject.value=theObject.value.bold();
	if(menuObject.FontItalic)theObject.value=theObject.value.italics();
	theObject.Ovalue=theObject.value;
	theObject.value=theObject.value.fontcolor(c);
	theObject.Ovalue=theObject.Ovalue.fontcolor(d);
	theObject.value=menuObject.CntrTxt+"<font face='"+menuObject.FontFamily+"' point-size='"+menuObject.FontSize+"'>"+theObject.value+menuObject.TxtClose;
	theObject.Ovalue=menuObject.CntrTxt+"<font face='"+menuObject.FontFamily+"' point-size='"+menuObject.FontSize+"'>"+theObject.Ovalue+menuObject.TxtClose;
	theObject.LoBck=a;
	theObject.HiBck=b;
	theObject.ChildCntnr=null;
	theObject.PrvMbr=PrMmbr;
	theObject.visibility='inherit';
	if(theObject.LoBck)theObject.bgColor=theObject.LoBck;
	theObject.resizeTo(Wdth,Hght);
	if(!menuObject.AcrssFrms&&eval(WhatMenu+'[2]'))theObject.background.src=eval(WhatMenu+'[2]');
	theObject.document.write(theObject.value);
	theObject.document.close();
	theObject.CmdLyr=new Layer(Wdth,MmbrCntnr);
	theObject.CmdLyr.MenuObject=menuObject;
	theObject.CmdLyr.Level=menuObject.RcrsLvl;
	theObject.CmdLyr.LinkTxt=eval(WhatMenu+'[1]');
	theObject.CmdLyr.visibility='inherit';
	theObject.CmdLyr.onmouseover=(menuObject.RcrsLvl==1&&menuObject.UnfoldsOnClick)?menuObject.OpenMenuClick:menuObject.OpenMenu;
	theObject.CmdLyr.onmouseout=menuObject.CloseMenu;
	theObject.CmdLyr.captureEvents(Event.MOUSEUP);
	theObject.CmdLyr.onmouseup=(menuObject.RcrsLvl==1&&menuObject.UnfoldsOnClick&&eval(WhatMenu+'[3]'))?menuObject.OpenMenu:menuObject.GoTo;
	theObject.CmdLyr.LowLyr=theObject;
	theObject.CmdLyr.resizeTo(Wdth,Hght);
	theObject.CmdLyr.Container=MmbrCntnr;
	if(eval(WhatMenu+'[3]')){
		theObject.CmdLyr.ImgLyr=new Layer(10,theObject.CmdLyr);
		theObject.CmdLyr.ImgLyr.visibility='inherit';
		theObject.CmdLyr.ImgLyr.top=(menuObject.RcrsLvl==1&&menuObject.FirstLineHorizontal)?Hght-7:Hght/2-5;
		theObject.CmdLyr.ImgLyr.left=(menuObject.RcrsLvl==1&&menuObject.FirstLineHorizontal)?Wdth-12:Wdth-7;
		theObject.CmdLyr.ImgLyr.width=(menuObject.RcrsLvl==1&&menuObject.FirstLineHorizontal)?10:5;
		theObject.CmdLyr.ImgLyr.height=(menuObject.RcrsLvl==1&&menuObject.FirstLineHorizontal)?5:10;
		menuObject.ImgStr=(menuObject.RcrsLvl==1&&menuObject.FirstLineHorizontal)?"<img src='"+menuObject.ArrowDownSrc+"'>":(menuObject.RightToLeft)?"<img src='"+menuObject.ArrowOtherSrc+"'>":"<img src='"+menuObject.ArrowRightSrc+"'>";
		theObject.CmdLyr.ImgLyr.document.write(menuObject.ImgStr);
		theObject.CmdLyr.ImgLyr.document.close()}}

function CreateMenuStructure(MName,NumberOf){
	//alert("CreateMenuStructure: " + this.Menu1);
	this.RcrsLvl++;
	var i,NoOffSubs,Mbr,Wdth=0,Hght=0;
	var PrvMmbr=null;
	var WMnu=MName+'1';
	var MenuWidth=eval(WMnu+'[5]');
	var MenuHeight=eval(WMnu+'[4]');
	var Location=(this.RcrsLvl==1)?this.FrstLoc:this.ScLoc;
	
	var MmbrCntnr;

	if (this.RcrsLvl==1&&this.FirstLineHorizontal){
		for(i=1;i<NumberOf+1;i++){WMnu=MName+eval(i);Wdth=(eval(WMnu+'[5]'))?Wdth+eval(WMnu+'[5]'):Wdth+MenuWidth}
		Wdth=(this.BorderBtwnElmnts)?Wdth+(NumberOf+1)*this.BorderWidth:Wdth+2*this.BorderWidth;Hght=MenuHeight+2*this.BorderWidth}
	else{	for(i=1;i<NumberOf+1;i++){WMnu=MName+eval(i);Hght=(eval(WMnu+'[4]'))?Hght+eval(WMnu+'[4]'):Hght+MenuHeight}
		Hght=(this.BorderBtwnElmnts)?Hght+(NumberOf+1)*this.BorderWidth:Hght+2*this.BorderWidth;Wdth=MenuWidth+2*this.BorderWidth}
	if(this.DomYes){
		MmbrCntnr=Location.document.createElement("div");
		MmbrCntnr.style.position='absolute';
		MmbrCntnr.style.visibility='hidden';
		Location.document.body.appendChild(MmbrCntnr)}
	else if(this.Nav4) MmbrCntnr=new Layer(Wdth,Location);
		else{	WMnu+='c';
			Location.document.body.insertAdjacentHTML("this.AfterBegin","<div id='"+WMnu+"' style='visibility:hidden; position:absolute;'><\/div>"); 
			MmbrCntnr=Location.document.all[WMnu]}
	/*  Pat changed this
	MmbrCntnr.SetUp=CntnrSetUp;
	MmbrCntnr.SetUp(Wdth,Hght,NumberOf);
	*/
		this.CntnrSetUp(MmbrCntnr,Wdth,Hght,NumberOf);
		//alert("test0");
	//change over
	if(this.Exp4){	MmbrCntnr.InnerString='';
		for(i=1;i<NumberOf+1;i++){
			WMnu=MName+eval(i);
			MmbrCntnr.InnerString+="<div id='"+WMnu+"' style='position:absolute;'><\/div>"}
		MmbrCntnr.innerHTML=MmbrCntnr.InnerString}
	for(i=1;i<NumberOf+1;i++){
		WMnu=MName+eval(i);
		NoOffSubs=eval(WMnu+'[3]');
		Wdth=(this.RcrsLvl==1&&this.FirstLineHorizontal)?(eval(WMnu+'[5]'))?eval(WMnu+'[5]'):MenuWidth:MenuWidth;
		Hght=(this.RcrsLvl==1&&this.FirstLineHorizontal)?MenuHeight:(eval(WMnu+'[4]'))?eval(WMnu+'[4]'):MenuHeight;
		if(this.DomYes){Mbr=Location.document.createElement("div");
			Mbr.style.position='absolute';
			Mbr.style.visibility='inherit';
			MmbrCntnr.appendChild(Mbr)}
		else Mbr=(this.Nav4)?new Layer(Wdth,MmbrCntnr):Location.document.all[WMnu];
		/*  Pat changed this
		Mbr.SetUp=(this.Nav4)?NavMbrSetUp:MbrSetUp;
		Mbr.SetUp(MmbrCntnr,PrvMmbr,WMnu,Wdth,Hght);
		*/
		//alert("test1");
		(this.Nav4)?this.NavMbrSetUp(this,Mbr,MmbrCntnr,PrvMmbr,WMnu,Wdth,Hght):this.MbrSetUp(Mbr,MmbrCntnr,PrvMmbr,WMnu,Wdth,Hght);
		//alert("test2")
		//end change
		
		if(NoOffSubs) Mbr.ChildCntnr=this.CreateMenuStructure(WMnu+'_',NoOffSubs);
		PrvMmbr=Mbr}
	MmbrCntnr.FrstMbr=Mbr;
	this.RcrsLvl--;
	return(MmbrCntnr)}

function CreateMenuStructureAgain(MName,NumberOf){
	//alert("CreateMenuStructureAgain: " + this.Menu1);
	var i,WMnu,NoOffSubs;
	var PrvMmbr,Mbr=this.FrstCntnr.FrstMbr;
	this.RcrsLvl++;
	for(i=NumberOf;i>0;i--){
		WMnu=MName+eval(i);
		NoOffSubs=eval(WMnu+'[3]');
		PrvMmbr=Mbr;
		if(NoOffSubs)Mbr.ChildCntnr=this.CreateMenuStructure(WMnu+'_',NoOffSubs);
		Mbr=Mbr.PrvMbr}
	this.RcrsLvl--}