javascript 不用控件如何控制页面打印的样式(左右边距等)! 主要是改变注册表里的HKEY_CURRENT_USER\Software\Microsoft\Internet Explorer\PageSetup里的 margin_bottom、margin_top、margin_left、margin_right的几个值就可以改动页面的四个边距 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <script language="VBScript">pbottom= '下边距ptop= '上边距pleft= '左边距pright= '右边距Set RegWsh = CreateObject("WScript.Shell")hkey_key="\margin_bottom"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pbottomhkey_key="\margin_top"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,ptophkey_key="\margin_left"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,plefthkey_key="\margin_right"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pright </script> 不好意思啊,漏了路径了<script language="VBScript">hkey_root="HKEY_CURRENT_USER"hkey_path="\Software\Microsoft\Internet Explorer\PageSetup"pbottom= '下边距ptop= '上边距pleft= '左边距pright= '右边距Set RegWsh = CreateObject("WScript.Shell")hkey_key="\margin_bottom"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pbottomhkey_key="\margin_top"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,ptophkey_key="\margin_left"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,plefthkey_key="\margin_right"RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pright </script> 直接用css。@media print {body {font-size:9pt; margin:10px 20px 30px 40px } } 感觉还是css可行, 想别人开ie就提示有修改注册表,很让人反感为病毒,呵, rising的功能.. javascript 随机数数组生成,显示、比较问题。 缺少对象,老查不出原因,急~~!!!! 怎样使页面格式不受浏览器的兼容模式影响 疯了,setAttribute(key,value)方法的问题。急 还是复选框问题,求教!! 请教一个javascript的参数传递 我真的很想学好js,但,我初学总碰到问题。能不能交个朋友。留下你的msn,QQ什么的?我最后25分了。 阿信哥哥,你的主页上的鼠标特效是怎么做的? Js的参数传递问题 如何点击A标签,让它的父容器背景颜色变化 javascrip怎么获得网址中的参数? 帮忙改进成动态菜单效果,谢谢
pbottom= '下边距
ptop= '上边距
pleft= '左边距
pright= '右边距
Set RegWsh = CreateObject("WScript.Shell")
hkey_key="\margin_bottom"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pbottom
hkey_key="\margin_top"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,ptop
hkey_key="\margin_left"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pleft
hkey_key="\margin_right"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pright
</script>
<script language="VBScript">
hkey_root="HKEY_CURRENT_USER"
hkey_path="\Software\Microsoft\Internet Explorer\PageSetup"
pbottom= '下边距
ptop= '上边距
pleft= '左边距
pright= '右边距
Set RegWsh = CreateObject("WScript.Shell")
hkey_key="\margin_bottom"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pbottom
hkey_key="\margin_top"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,ptop
hkey_key="\margin_left"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pleft
hkey_key="\margin_right"
RegWsh.RegWrite hkey_root+hkey_path+hkey_key,pright
</script>
body {font-size:9pt; margin:10px 20px 30px 40px }
}