﻿  var TheNote;
  
  function OpenPopup(mylink, windowname) {
    var href,hw;
    if (typeof(mylink) == 'string')
     href=mylink;
    else
     href=mylink.href;
    hw = window.open(href, windowname, 'width=450,height=500,scrollbars=yes,resizable=yes');
    hw.focus();
  return false;
  }
  
  function OpenNote(mylink) {
    var href;
    href = 'Note.aspx?FName=' + mylink;
    TheNote = window.open(href, 'Note', 'width=400,height=200,scrollbars=yes,resizable=yes');
    TheNote.focus();
    return false;
  }
  
  function OpenImage(mylink) {
    var href;
    href = 'Image.aspx?FName=' + mylink + '&X=' + self.screen.availWidth + '&Y=' + self.screen.availHeight;
    TheNote = window.open(href, 'Note', 'width=400,height=200,scrollbars=yes,resizable=no');
    TheNote.focus();
    return false;
  }
  
  function OpenImageZ(mylink) {
    var href;
    href = 'ImageZ.aspx?FName=' + mylink + '&X=' + self.screen.availWidth + '&Y=' + self.screen.availHeight;
    TheNote = window.open(href, 'Note', 'width=640,height=480,scrollbars=yes,resizable=yes');
    TheNote.focus();
    return false;
  }
  
  function docPrint() {
    var href;
    href = 'DocPrint.aspx';
    TheNote = window.open(href, 'Print', 'width=400,height=200,scrollbars=yes,resizable=no');
    return false;
  }
  
  function showFirstHIL(Id) {
    var el = document.getElementById(Id);
    if (el != null) el.scrollIntoView(true);
  }
  
  function noEnter() {
    if (window.event.keyCode == 13) {
      event.returnValue=false; 
      event.cancel = true;
    }
  }
  
  function doJumpTo(o)
  {
    var arg = o.getAttribute("ID");
    __doPostBack("spl1$jumpto", arg);
  }  
