var lastobj = null;
function showdiv(obj){
	var oldobj = obj;
	if(!obj){
		if(lastobj)lastobj.style.display = 'none';
		return;
	}
	
	var divname = obj.childmenu
	var obj = document.all(divname);
	if(obj){
		if(lastobj)	lastobj.style.display = 'none';
		obj.style.display = '';
		lastobj = obj;
	}
}

function checkRange(obj){
	var toObj = event.toElement;
	if(toObj&&toObj.childmenu==obj.id)return;
	while(toObj){
		if(toObj==obj)
			return
		toObj = toObj.parentElement;
	};
	showdiv(null)
}
function checkRangeA(obj){
	var toObj = event.toElement;
	while(toObj){
		if(toObj==document.all(obj.childmenu))
			return;
		toObj = toObj.parentElement;
	}
	showdiv(null);
}

