function getHtmlElement(Jb)
{
	return document.getElementById(Jb);
}

function showHtmlElement(Jb)
{
    var x = getHtmlElement(Jb);
    if (x != null)
    {
        x = x.style;
        x.display = "inline";
    }
}

function hideHtmlElement(Jb)
{
    var x = getHtmlElement(Jb);
    if (x != null)
    {
        x = x.style;
        x.display = "none";
    }
}

function changeHtmlElement(Jb)
{
    var x = getHtmlElement(Jb).style;
    if (x.display == "none")
    {
        x.display = "inline";
    }
    else
    {
        x.display = "none";
    }
}
function doHourglass()
{
  document.body.style.cursor = 'wait';
}

/*****************************************************************************
 *  Objective: Clear all input objects from the form passed as parameter
 *  Usage: 
 *
 *****************************************************************************/
function clear_form(xFormName) 
{
    var arrElems = document.forms[xFormName].elements;
    document.forms[xFormName].reset();
    for(xi=0;xi<arrElems.length;xi++){
      if(arrElems[xi].type.toLowerCase() == "text" ||
         arrElems[xi].type.toLowerCase() == "password" ||
         arrElems[xi].type.toLowerCase() == "textarea")
        arrElems[xi].value="";
      else if(arrElems[xi].type.toLowerCase() == "radio" ||
              arrElems[xi].type.toLowerCase() == "checkbox")
        arrElems[xi].selected = false;
      else if(arrElems[xi].type.toLowerCase().indexOf("select") != -1)
        arrElems[xi].selectedIndex = -1;
    }
}

function showWindowDoc(content)
{
	summary_popup = window.open(content, 'Document', 'left=0,top=0,menubar=yes,width=750,height=500,resizable=yes,scrollbars=yes');
	summary_popup.focus();
}

function showWindowEx(WindowName, content)
{
	win = window.open(content, name, 'status=yes,scrollbars=yes,width=700,height=480,top=200,left=200');
	win.focus();
}