Friday 19 April 2013

Remove scroll then print all data using javascript



function getForm()
    {
   
        var prtContent = document.getElementById('divPrintSupplierBill');
       var WinPrint = window.open('','','letf=100,top=100,width=1000px,height=640px,toolbar=1,scrollbars=1,status=1');
       WinPrint.document.write(prtContent.outerHTML);
       WinPrint.document.close();
       WinPrint.focus();
       WinPrint.print();
     //WinPrint.close();
       //prtContent.innerHTML=strOldOne;
    }
   
    function disableBtn() {
    document.getElementById("btnPrintInvoice").disabled=true
}





function ff()
    {
   var tt= document.getElementById("ctl00_ContentPlaceHolder1_pnlSupplierBilDetail");
    tt.style.cssText='overflow-y:hidden';
    getForm();
    scrollallow();
    return false;
    }
function scrollallow()
{
var tt= document.getElementById("ctl00_ContentPlaceHolder1_pnlSupplierBilDetail");
   tt.style.cssText='overflow-y:scroll;Height:350px';
    return false;
}

No comments:

Post a Comment

Excel Sort values in ascending order using function TEXTJOIN

 Excel ::  Text ::  1,3,5,2,9,5,11 Result :: 1,2,3,5,5,9,11 Formula ::     TEXTJOIN ( ",",1,SORT(MID(SUBSTITUTE( A1 ,","...