function tree1(tm0,tm1){
	this.tm2=tm1;
	this.tm3=tm0;
	this.tm4=this;
	this.tm5=[];
	this.tm6=null;
	this.tm7=-1;
	var tm8=new Image(),tm9=new Image();
	tm8.src=tm1['icon_e'];
	tm9.src=tm1['icon_l'];
	tm1['im_e']=tm8;
	tm1['im_l']=tm9;
	for(var i=0;i<64;i++)
		if(tm1['icon_'+i]){
			var tmA=new Image();
			tm1['im_'+i]=tmA;
			tmA.src=tm1['icon_'+i]
		}
	this.tmB=function(tmC){var tmD=this.tm5[tmC];tmD.tmE(tmD.tmF)};
	this.tmG=function(tmC){return this.tm5[tmC].tmG()};
	this.tmH=function(tmC){this.tm5[tmC].tmI(true)};
	this.tmJ=function(tmC){this.tm5[tmC].tmI()};
	this.tmK=[];
	for(var i=0;i<tm0.length;i++)
		new tmL1(this,i);
	this.tmC=trees.length;
	trees[this.tmC]=this;
	for(var i=0;i<this.tmK.length;i++){
		document.write(this.tmK[i].tmM());
		this.tmK[i].tmE()
	}
}
	
function tmL1(tmN,tmO){
	this.tm7=tmN.tm7+1;
	this.tm3=tmN.tm3[tmO+(this.tm7?2:0)];
	if(!this.tm3)
		return;
	this.tm4=tmN.tm4;
	this.tmN=tmN;
	this.tmO=tmO;
	this.tmF=!this.tm7;
	this.tmC=this.tm4.tm5.length;
	this.tm4.tm5[this.tmC]=this;
	tmN.tmK[tmO]=this;
	this.tmK=[];
	for(var i=0;i<this.tm3.length-2;i++)
		new tmL1(this,i);
	this.tmP=tmQ1;
	this.tmE=tmR1;
	this.tmG=tmS1;
	this.tmM=tmT1;
	this.tmI=tmU1;
	this.tmV=function(){return this.tmO==this.tmN.tmK.length-1}
}

function tmR1(tmW){
	var tmX=tmY('i_div'+this.tm4.tmC+'_'+this.tmC);
	if(!tmX)return;
	if(!tmX.innerHTML){
		var tmK=[];
		for(var i=0;i<this.tmK.length;i++)
			tmK[i]=this.tmK[i].tmM();
		tmX.innerHTML=tmK.join('')
	}
	tmX.style.display=(tmW?'none':'block');
	this.tmF=!tmW;
	var tmZ=document.images['j_img'+this.tm4.tmC+'_'+this.tmC],tma=document.images['i_img'+this.tm4.tmC+'_'+this.tmC];
	if(tmZ)
		tmZ.src=this.tmP(true);
	if(tma)
		tma.src=this.tmP();
	this.tmI()
}

function tmS1(tmb){
	if(!tmb){
		var tmc=this.tm4.tm6;
		this.tm4.tm6=this;
		if(tmc)
			tmc.tmG(true)
	}
	var tma=document.images['i_img'+this.tm4.tmC+'_'+this.tmC];
	if(tma)tma.src=this.tmP();
	tmY('i_txt'+this.tm4.tmC+'_'+this.tmC).style.fontWeight=tmb?'normal':'bold';
	this.tmI();
	return Boolean(this.tm3[1])
}

function tmU1(tmd){
	window.setTimeout('window.status="'+(tmd?'':this.tm3[0]+(this.tm3[1]?' ('+this.tm3[1]+')':''))+'"',10)
}

function tmT1(){
	var tme=[],tmf=this.tmN;
	for(var i=this.tm7;i>1;i--){
		tme[i]='<img src="'+this.tm4.tm2[tmf.tmV()?'icon_e':'icon_l']+'" border="0" align="absbottom" style="display:inline">';
		tmf=tmf.tmN
	}
	return '<table cellpadding="0" cellspacing="0" border="0"><tr><td nowrap>'+(this.tm7?tme.join('')+(this.tmK.length?'<a href="javascript: trees['+this.tm4.tmC+'].tmB('+this.tmC+')" onmouseover="trees['+this.tm4.tmC+'].tmJ('+this.tmC+')" onmouseout="trees['+this.tm4.tmC+'].tmH('+this.tmC+')"><img src="'+this.tmP(true)+'" border="0" align="absbottom" name="j_img'+this.tm4.tmC+'_'+this.tmC+'" style="display:inline"></a>':'<img src="'+this.tmP(true)+'" border="0" align="absbottom" style="display:inline">'):'')+'<span id="dd" onclick="callMe1(\''+this.tm3[0]+'\')" class="t'+this.tm4.tmC+'i" id="i_txt'+this.tm4.tmC+'_'+this.tmC+'"><img src="'+this.tmP()+'" border="0" align="absbottom" name="i_img'+this.tm4.tmC+'_'+this.tmC+'" class="t'+this.tm4.tmC+'im" style="display:inline">'+this.tm3[0]+'</span></td></tr></table>'+(this.tmK.length?'<div id="i_div'+this.tm4.tmC+'_'+this.tmC+'" style="display:none"></div>':'')


//return '<table cellpadding="0" cellspacing="0" border="0"><tr><td nowrap>'+(this.tm7?tme.join('')+(this.tmK.length?'<a href="javascript: trees['+this.tm4.tmC+'].tmB('+this.tmC+')" onmouseover="trees['+this.tm4.tmC+'].tmJ('+this.tmC+')" onmouseout="trees['+this.tm4.tmC+'].tmH('+this.tmC+')"><img src="'+this.tmP(true)+'" border="0" align="absbottom" name="j_img'+this.tm4.tmC+'_'+this.tmC+'"></a>':'<img src="'+this.tmP(true)+'" border="0" align="absbottom">'):'')+'<a href="'+this.tm3[1]+'" target="'+this.tm4.tm2['target']+'" onclick="return trees['+this.tm4.tmC+'].tmG('+this.tmC+')" ondblclick="trees['+this.tm4.tmC+'].tmB('+this.tmC+')" onmouseover="trees['+this.tm4.tmC+'].tmJ('+this.tmC+')" onmouseout="trees['+this.tm4.tmC+'].tmH('+this.tmC+')" class="t'+this.tm4.tmC+'i" id="i_txt'+this.tm4.tmC+'_'+this.tmC+'"><img src="'+this.tmP()+'" border="0" align="absbottom" name="i_img'+this.tm4.tmC+'_'+this.tmC+'" class="t'+this.tm4.tmC+'im">'+this.tm3[0]+'</a></td></tr></table>'+(this.tmK.length?'<div id="i_div'+this.tm4.tmC+'_'+this.tmC+'" style="display:none"></div>':'')
}

function tmQ1(tmg){
	return this.tm4.tm2['icon_'+((this.tm7?0:32)+(this.tmK.length?16:0)+(this.tmK.length&&this.tmF?8:0)+(!tmg&&this.tm4.tm6==this?4:0)+(tmg?2:0)+(tmg&&this.tmV()?1:0))]}var trees=[];tmY=document.all?function(tmh){return document.all[tmh]}:function(tmh){return document.getElementById(tmh)
};

function callMe1(val){
	if(val.indexOf("~")==-1){
		//alert("Biyat="+val);
		var boxLength = document.frmGetData.choiceBoxTypes.length;
		var exists = false;
		var tempVal;
		var count = 0;
		for (i = 0; i < boxLength; i++) {
			//if (document.frmGetData.choiceBoxTypes.options[i].selected) {
				tempVal = document.frmGetData.choiceBoxTypes.options[i].value;
				if(val==tempVal){
					exists = true;
				}
			//}
		}
		if(!exists){
			newoption = new Option(val, val, false, false);
			document.frmGetData.choiceBoxTypes.options[boxLength] = newoption;
		}


	}	
}

function removeMe1() {
	var boxLength = document.frmGetData.choiceBoxTypes.length;
	arrSelected = new Array();
	var count = 0;
	for (i = 0; i < boxLength; i++) {
		if (document.frmGetData.choiceBoxTypes.options[i].selected) {
			arrSelected[count] = document.frmGetData.choiceBoxTypes.options[i].value;
		}
		count++;
	}
	var x;
	for (i = 0; i < boxLength; i++) {
		for (x = 0; x < arrSelected.length; x++) {
			if (document.frmGetData.choiceBoxTypes.options[i].value == arrSelected[x]) {
				document.frmGetData.choiceBoxTypes.options[i] = null;
			}
		}
		boxLength = document.frmGetData.choiceBoxTypes.length;
   }
}




function SelectAll1(val) {

var selectedItem ;
var selectedText ;
var selectedValue ;
var i;
var newoption;

var temp = new Array();
temp = val.split(',');
  
for (i = 0; i <temp.length; i++) {

newoption = new Option(temp[i], temp[i], false, false);
document.frmGetData.choiceBoxTypes.options[i] = newoption;
	
}

}


function RemoveAll1(){
	
var boxLength = document.frmGetData.choiceBoxTypes.length;	
var j;
for(i = 0; i < boxLength; i++){
j=0;
document.frmGetData.choiceBoxTypes.options[j] = null;

}

}
