﻿
function GEI(Id){return document.getElementById(Id);}
function HideElem(Elem)
{
  Elem.style.display="none";
}

function ShowElem(Elem)
{
  Elem.style.display="block";
}


function Print2(Elem,Id)
{
    HideElem(Elem);
    Print(Id);
    ShowElem(Elem);
}

function  Print(Id)
{
        var Elem=GEI(Id);
        if(Elem!=null)
        {
                var html="";
                html='<html>'+
                        '<head>'+
                            '<link href="/Site/Headers/CSS/Bihar_Layout.css" rel="stylesheet" type="text/css" />'+
                            '<link href="/Site/Headers/CSS/Bihar_content.css" rel="stylesheet" type="text/css" />'+
                            '<link href="/Site/Headers/CSS/Bihar_homepage.css" rel="stylesheet" type="text/css" />'+
                        '</head>'+
                        '<body>'+
                            '<div style="text-align:center;width:100%;">'+
                               // '<img src="/site/Headers/images/Biharlogo.png" alt="Bihar Logo" border="0" /><br/>'+
                                Elem.innerHTML+
                              '<br/>'+
                              '<div style="text-align:right"><i>This page is generated at http://www.BiharOnline.gov.in.<br/>Copyright © 2008 Bihar e-Governance Services & Technology Ltd.</i></div>'+
                            '</div>'+
                        '</body>'+
                    '</html>';
            var wp=  window.open("","BhPrint","toolbar=yes,location=no,directories=yes,menubar=yes,scrollbars=yes,left=120,top=0");
            wp.document.open();wp.document.write(html);wp.document.close();
            wp.focus();wp.print();wp.close();
        }
        

}
