

function popFullImage(ImgName,ImgWidth,ImgHeight)
{
   var winWidth = parseInt(ImgWidth + parseInt(50))
   var winHeight = parseInt(ImgHeight) + parseInt(90)
   var popWindow = window.open("","Package","width=" + winWidth + ",height=" + winHeight + ",toolbar=0,scrollbars=1,location=0,statusbar=1,menubar=0,resizable=1");
   
   popWindow.document.writeln("<html><head><title>Enlarge Image</title></head>");
   popWindow.document.writeln("<body topmargin=0 leftmargin=0 marginwidth=0 marginheight=0>");
   popWindow.document.writeln("<center><table border=0 cellpadding=0 cellspacing=0>");
   popWindow.document.writeln("<tr><td colspan=\"2\" class=\"BODY_FONT\"><b><u><img style=\"border:solid 5px #ffffff;\" src=\"" + ImgName + "\" width=\"" + ImgWidth + "\" height=\"" + ImgHeight + "\" border=\"0\"></u></b></td></tr>");
   popWindow.document.writeln("<tr><td colspan=\"2\" align=\"center\"><br><input type=\"button\" name=\"Task\" value=\"Close\" onClick=\"window.close()\"></td></tr>");
   popWindow.document.writeln("</table></center>");
   popWindow.document.writeln("</body></html>");
}

function popFullPage(PageName,winWidth,winHeight)
{
   window.open(PageName,"Package","width=" + winWidth + ",height=" + winHeight + ",toolbar=0,scrollbars=1,location=0,statusbar=1,menubar=0,resizable=1");
}


function numbersonly(myfield, e, dec)
{
var key;
var keychar;

if (window.event)
   key = window.event.keyCode;
else if (e)
   key = e.which;
else
   return true;
keychar = String.fromCharCode(key);

// control keys
if ((key==null) || (key==0) || (key==8) || 
    (key==9) || (key==13) || (key==27) )
   return true;

// numbers
else if ((("0123456789").indexOf(keychar) > -1))
   return true;

// decimal point jump
else if (dec && (keychar == "."))
   {
   myfield.form.elements[dec].focus();
   return false;
   }
else
   return false;
}
