function openNewWindow(pi_sURL, pi_iWidth, pi_iHeight, pi_sWindowName) { var l_iWidth = 450; var l_iHeight = 550; var l_iTop = 272; var l_iLeft = 114; var l_dDate = new Date(); if (pi_iWidth != "undefined") l_iWidth = pi_iWidth if (pi_iHeight != "undefined") l_iHeight = pi_iHeight var l_sEG = 'Menubar=no'+ ',Toolbar=no'+ ',Directories=no'+ ',status=yes'+ ',resizable=no'+ ',scrollbars=no'+ ',top='+ l_iTop + ',left=' + l_iLeft + ',width='+ l_iWidth + ',height=' + l_iHeight; //alert(l_sEG); var l_oWindow = window.open(pi_sURL, pi_sWindowName, l_sEG); if (isValid(l_oWindow)) { l_oWindow.focus(); } } function isValid(pi_oObject) { if ( pi_oObject == null || pi_oObject == "" || pi_oObject == "undefined" || typeof(pi_oObject) == "undefined" ) return false; else return true; } function selectAll(pi_sFormName, pi_sElementName, pi_bChecked) { var l_oElementsCollection = document.forms[pi_sFormName].elements[pi_sElementName]; if (isValid(l_oElementsCollection)) { if (!l_oElementsCollection.length) { l_oElementsCollection.checked = true; } else { for(var i = 0; i < l_oElementsCollection.length; i++) { l_oElementsCollection[i].checked = pi_bChecked; }//for(var i = 0; i < l_oElementsCollection.length; i++) } } // if (isValid(l_oElementsCollection)) } // function selectAll() function confirmDelete(pi_sMessage, pi_sURL) { //alert(deleteImage); var l_bCheck = confirm(pi_sMessage); if(l_bCheck == true) { window.location.href = pi_sURL; } } function trim(pi_sValue) { // Remove leading spaces and carriage returns while ((pi_sValue.substring(0,1) == ' ') || (pi_sValue.substring(0,1) == '\n') || (pi_sValue.substring(0,1) == '\r')) { pi_sValue = pi_sValue.substring(1,pi_sValue.length); } // Remove trailing spaces and carriage returns while ((pi_sValue.substring(pi_sValue.length-1,pi_sValue.length) == ' ') || (pi_sValue.substring(pi_sValue.length-1,pi_sValue.length) == '\n') || (pi_sValue.substring(pi_sValue.length-1,pi_sValue.length) == '\r')) { pi_sValue = pi_sValue.substring(0,pi_sValue.length-1); } return pi_sValue; }