//Variables used within some fuctions below. NS4 = (document.layers); IE4 = (document.all); ver4 = (NS4 || IE4); isMac = (navigator.appVersion.indexOf("Mac") != -1); isMenu = ((NS4 && !isMac) || (IE4 && !isMac)); //Function is used to change the class name. function chgCL(src,clName) { src.className = clName; } //Function is used to change the image. function chgImage(src,image) { document [src].src = image; } //Function is used to select and deselect all checkboxes. function doCheckbox(src) { for (var x=0;x 0) { var docURL = "sys_agtRD?OpenAgent" + docUNID; var delWin = open(docURL, '_blank', 'width=300, height=150,top=200,left=200,scrollbars'); } } } //Copy all of selected checkboxes within the view. function copySel() { var docUNID=""; var doc = document.main; var count = 0; for (var i=0;i 0) { var docURL = "sys_agtCD?OpenAgent" + docUNID; var copyWin = open(docURL, '_blank', 'width=300, height=150,top=200,left=200,scrollbars'); } } //Function is used to create a new document. function createDoc() { var wPath = "exp_doc?OpenForm" + qstring; window.location.href= wPath; } //Function is used to submit the form if the date //field is not blank. function submitPage() { with (document.forms[0]) { if (entDate.value=="") alert("Please enter a Date."); else submit(); } } //Function is used to edit the document using the unid //that is passed to it. function editPage(unid) { wPath = "/" + dbPath + "/sys_all/" + unid + "?EditDocument" + qstring; window.location.href= wPath; } //Function returns the user to the correct previous location. function returnPage() { wPath = "/" + dbPath + "/sys_wv?OpenForm" + qstring; window.location.href= wPath; } function trim(stringa) { while (stringa.substring(0,1) == ' ') { stringa = stringa.substring(1, stringa.length); } while (stringa.substring(stringa.length-1, stringa.length) == ' ') { stringa = stringa.substring(0,stringa.length-1); } return stringa; } function Left(str, n) { if (n <= 0) return ""; else if (n > String(str).length) return str; else return String(str).substring(0,n); } function Right(str, n){ if (n <= 0) return ""; else if (n > String(str).length) return str; else { var iLen = String(str).length; return String(str).substring(iLen, iLen - n); } }