var shell;
function SetPrintProperties() {
try {
shell = new ActiveXObject("WScript.Shell");
shell.SendKeys("%fu");
window.setTimeout("javascript:SetPaperSize();", 400);
} catch (e) {
alert(′Please verify that your print settings have a Landscape
orientation and minimum margins.′);
}
} 数据挖掘研究院
function SetPaperSize() {
shell.sendKeys("%a{TAB}.2{TAB}0{TAB}0{TAB}0{ENTER}");
}

