Control "vertical hit", Horizontal Dozen "and" page margins, remove the header, pagination ... Print Encyclopedia

Source: Internet
Author: User
Web Printing Daquan: (Turn cut plum blossom rain)
1, control "vertical dozen", horizontal dozen "and" the margins of the page.
(1) <script defer>
function Setprintsettings () {
--Advanced Features
Factory.printing.SetMarginMeasure (2)//measure margins in inches
Factory. Setpagerange (False, 1, 3)//need pages from 1 to 3
Factory.printing.printer = "HP DeskJet 870C"
Factory.printing.copies = 2
Factory.printing.collate = True
Factory.printing.paperSize = "A4"
Factory.printing.paperSource = "Manual feed"
--Basic features
Factory.printing.header = "This is Meadco"
Factory.printing.footer = "Advanced printing by ScriptX"
Factory.printing.portrait = False
Factory.printing.leftMargin = 1.0
Factory.printing.topMargin = 1.0
Factory.printing.rightMargin = 1.0
Factory.printing.bottomMargin = 1.0
}
</script>
(2)
<script language= "JavaScript" >
function Printsetup () {
Print Page Setup
WB.EXECWB (8,1);
}
function PrintPreview () {
Print Page Preview
WB.EXECWB (7,1);
}
function PrintIt ()
{
if (confirm) (' OK to print? ')) {
WB.EXECWB (6,6)
}
}
</script>
<body>
<object classid= "CLSID:8856F961-340A-11D0-A96B-00C04FD705A2"
Height=0 ID=WB NAME=WB width=0></object>
<input Type=button name=button_print value= "print"
Onclick= "Javascript:printit ()" >
<input Type=button name=button_setup value= "Print Page Setup"
Onclick= "Javascript:printsetup ();" >
<input Type=button name=button_show value= "Print Preview"
Onclick= "Javascript:printpreview ();" >
<input Type=button name=button_fh value= "Off"
Onclick= "Javascript:window.close ();" >

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.