您好,登錄后才能下訂單哦!
---testATGridPrint.aspx
<html>
<head>
<title>New Page 1 </title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
</head>
<body>
<p align="center">
<OBJECT id="ATGrid1" height="480" ;680" classid="clsid:D0CB6A0C-E656-4BF4-BD2D-6AE5EC183D7C">
<PARAM NAME="FileName" VALUE="CaiGouDingDan1.eT">
<PARAM NAME="BackColor" VALUE="#ffe7dd">
<PARAM NAME="Border3D" VALUE="FALSE">
<PARAM NAME="Ruler" VALUE="FALSE">
<PARAM NAME="DataSource" VALUE="importData3.aspx">
</OBJECT>
</p>
<p align="center">
<input type='button' value='打印預覽' onclick='javascript:printPreviewRpt();'>
<input type='button' value='打印一份' onclick='javascript:printRpt();'>
<input type='button' value='連續打印' onclick='javascript:printRpt10();'>
</p>
<script language="JavaScript">
function PrintSetup()
{
var strXML;
strXML = " <?xml version='1.0' encoding='gb2312'?>";
strXML =" <EtCell>";
strXML =" <ETPrint>";
strXML =" <PaperSize value='DMPAPER_USER' depth='cm' '11' Height='8' />";
strXML =" <PrintFullPage value='true' /> ";
strXML =" </ETPrint>";
strXML =" </EtCell>";
//設置打印選項
ATGrid1.ImportXML(strXML);
}
function printPreviewRpt()
{
PrintSetup();
ATGrid1.PrintPreview();
}
function printRpt()
{
//下面導入數據
/*
ATGrid1.OpenDoc(xxx.et);
ATGrid1.ImportXML(url?參數);
ATGrid1.Print(false);
*/
PrintSetup();//設置紙張大小
ATGrid1.Print(false);
}
function printRpt10()
{
//循環打印10份
for(ii=0;ii <10;ii )
{
printRpt();
}
}
</SCRIPT>
</body>
</html>
免責聲明:本站發布的內容(圖片、視頻和文字)以原創、轉載和分享為主,文章觀點不代表本網站立場,如果涉及侵權請聯系站長郵箱:is@yisu.com進行舉報,并提供相關證據,一經查實,將立刻刪除涉嫌侵權內容。