function iteminfowindow(infohtm, infoName, infoHeight, infoWidth) {
      /*Following formulas will center window for JavaScript 1.2+,
      including both Firefox 1+ and Internet Explorer 6+.*/
      var wndTop  = (screen.height - infoHeight) / 2;
		if (infoWidth == null)
			infoWidth = '450';
		var wndLeft = (screen.width  - infoWidth)  / 2;
		var scrWidth = new Number(screen.width);
		if (parseInt(infoWidth) > screen.width)
			infoWidth = scrWidth.toString;
		/*var infoWidth= '450';*/
		/*var winFeatures = 'height=' + infoHeight + ',width=800,top=' + wndTop + ',left=' + wndLeft + ',location=no,resizable=yes,status=no,toolbar=no,scrollbars=yes';*/
		var winFeatures = 'height=' + infoHeight + ',width=' + infoWidth + ',top=' + wndTop + ',left=' + wndLeft + ',location=no,resizable=yes,status=no,toolbar=no,scrollbars=yes';
		var infoWindow = window.open(infohtm,infoName,winFeatures);
		}

function changeDisplayState (id) {
    e=document.getElementById(id);
    if (e.style.display == 'none' || e.style.display =="") {
     e.style.display = 'block';
     /*showhide.innerHTML = 'Hide example';
     showhide.style.color='green';*/
    } else {
     e.style.display = 'none';
     /*showhide.innerHTML = 'Show example';*/
    }
   }
   
function displayOneHideOthers (id, idArray) {
	var eArray = new Array();
	eArray = idArray.split(",");
	e=document.getElementById(id);
	e.style.display = 'block';
	for (var i = 0; i < eArray.length; i++) {
		e=document.getElementById(eArray[i]);
		e.style.display = 'none'; }
    }
    
function setTabIndex(tabContainerClientID,index){
/* Changes active tab in an AJAXControlToolkit
tab control.*/
var tabs = $find(tabContainerClientID);
tabs.set_activeTabIndex(index);
}
