濮阳杆衣贸易有限公司

主頁 > 知識庫 > 利用vbs腳本實現(xiàn)設置IE的打印頁眉頁腳信息

利用vbs腳本實現(xiàn)設置IE的打印頁眉頁腳信息

熱門標簽:外呼系統(tǒng)免費招代理 廣州ai電銷機器人一般多少錢 外呼系統(tǒng)telrobot 合肥高德地圖標注 外呼線路中繼線是什么 怎么看地圖標注 深圳外呼系統(tǒng)收費 拉薩外呼系統(tǒng)業(yè)務 百度地圖標注是什么意思
將下面的內(nèi)容保存成.vbs文件,然后雙擊執(zhí)行,在打開ie頁面,在頁面中點擊右鍵,看看菜單中多了個什么?。。海?nbsp;


    
復制代碼 代碼如下:

option explicit 

    dim hkey_root,hkey_path,hkey_key,filepath 
    dim fs,fso,regwsh 

    hkey_root="hkey_current_user" 
    hkey_path="\software\microsoft\internet explorer" 

    //先創(chuàng)建文件 
    set fs=wscript.createobject("scripting.filesystemobject") 
    filepath="c:\pagesetup_default.htm" 
    set fso=fs.createtextfile(filepath,true) 
    fso.write("script language=""vbscript"">"+vbcrlf _ 
            +"dim hkey_root,hkey_path,hkey_key,filepath,regwsh" +vbcrlf _ 
            +"hkey_root=""hkey_current_user""" +vbcrlf _ 
            +"hkey_path=""\software\microsoft\internet explorer""" +vbcrlf _ 
            +"filepath=""c:\pagesetup_null.htm""" +vbcrlf _ 
            +"http://設置網(wǎng)頁打印的頁眉頁腳為默認值"+vbcrlf  _ 
            +"set regwsh = createobject(""wscript.shell"")" +vbcrlf _ 
            +"hkey_key=""\pagesetup\header""" +vbcrlf _ 
            +"regwsh.regwrite hkey_root+hkey_path+hkey_key,""wb頁碼:p/p""" +vbcrlf _ 
            +"hkey_key=""\pagesetup\footer""" +vbcrlf _ 
            +"regwsh.regwrite hkey_root+hkey_path+hkey_key,""ubd""" +vbcrlf _ 
            +"http://設置右鍵菜單上的顯示文字" +vbcrlf _ 
            +"http://首先刪除原來的項,然后再設置新的項"+vbcrlf  _ 
            +"on error resume next" +vbcrlf _ 
            +"hkey_key=hkey_root+hkey_path+""\menuext\打印時恢復頁眉頁腳\""" +vbcrlf _ 
            +"regwsh.regdelete hkey_key" +vbcrlf _ 
            +"hkey_key=hkey_root+hkey_path+""\menuext\打印時去掉頁眉頁腳\""" +vbcrlf _ 
            +"regwsh.regwrite hkey_key,filepath" +vbcrlf _ 
            +"http://關閉regwsh" +vbcrlf _ 
            +"set regwsh=nothing"+vbcrlf  _ 
        +"/script>") 
    fso.close 

    filepath="c:\pagesetup_null.htm" 
    set fso=fs.createtextfile(filepath,true) 
    fso.write("script language=""vbscript"">" +vbcrlf _ 
            +"dim hkey_root,hkey_path,hkey_key,filepath,regwsh" +vbcrlf _ 
            +"hkey_root=""hkey_current_user""" +vbcrlf _ 
            +"hkey_path=""\software\microsoft\internet explorer""" +vbcrlf _ 
            +"filepath=""c:\pagesetup_default.htm""" +vbcrlf _ 
            +"http://設置網(wǎng)頁打印的頁眉頁腳為空" +vbcrlf _ 
            +"set regwsh =createobject(""wscript.shell"")" +vbcrlf _ 
            +"hkey_key=""\pagesetup\header""" +vbcrlf _ 
            +"regwsh.regwrite hkey_root+hkey_path+hkey_key,""""" +vbcrlf _ 
            +"hkey_key=""\pagesetup\footer""" +vbcrlf _ 
            +"regwsh.regwrite hkey_root+hkey_path+hkey_key,""""" +vbcrlf _ 
            +"http://設置右鍵菜單上的顯示文字" +vbcrlf _ 
            +"http://首先刪除原來的項,然后再設置新的項" +vbcrlf _ 
            +"on error resume next"+vbcrlf  _ 
            +"hkey_key=hkey_root+hkey_path+""\menuext\打印時去掉頁眉頁腳\""" +vbcrlf _ 
            +"regwsh.regdelete hkey_key"+vbcrlf  _ 
            +"hkey_key=hkey_root+hkey_path+""\menuext\打印時恢復頁眉頁腳\""" +vbcrlf _ 
            +"regwsh.regwrite hkey_key,filepath" +vbcrlf _ 
            +"http://關閉regwsh" +vbcrlf _ 
            +"set regwsh=nothing"+vbcrlf  _ 
        +"/script>") 
    fso.close 

    set regwsh=wscript.createobject("wscript.shell") 
    hkey_key=hkey_root+hkey_path+"\menuext\打印時去掉頁眉頁腳\" 
    regwsh.regwrite hkey_key,"c:\pagesetup_null.htm" 

以上信息與文章正文是不可分割的一部分,如果您要轉載本文章,請保留以上信息,謝謝! 
您可能感興趣的文章:
  • 添加網(wǎng)站到安全站點.設置安全站點打開ActiveX時提示.去頁眉頁腳的vbs代碼
  • IE瀏覽器打印的頁眉頁腳設置解決方法
  • js實現(xiàn)頁面打印功能實例代碼(附去頁眉頁腳功能代碼)
  • JS調(diào)用打印方法設置頁眉頁腳的實例
  • javascript仿php的print_r函數(shù)輸出json數(shù)據(jù)
  • javascript實現(xiàn)window.print()去除頁眉頁腳

標簽:玉林 廣安 臺灣 延安 周口 六安 漳州 嘉興

巨人網(wǎng)絡通訊聲明:本文標題《利用vbs腳本實現(xiàn)設置IE的打印頁眉頁腳信息》,本文關鍵詞  利用,vbs,腳本,實現(xiàn),設置,;如發(fā)現(xiàn)本文內(nèi)容存在版權問題,煩請?zhí)峁┫嚓P信息告之我們,我們將及時溝通與處理。本站內(nèi)容系統(tǒng)采集于網(wǎng)絡,涉及言論、版權與本站無關。
  • 相關文章
  • 下面列出與本文章《利用vbs腳本實現(xiàn)設置IE的打印頁眉頁腳信息》相關的同類信息!
  • 本頁收集關于利用vbs腳本實現(xiàn)設置IE的打印頁眉頁腳信息的相關信息資訊供網(wǎng)民參考!
  • 推薦文章
    仁寿县| 昌平区| 从江县| 赞皇县| 保靖县| 永善县| 泽普县| 都昌县| 旬阳县| 荆门市| 奈曼旗| 府谷县| 凌源市| 嘉禾县| 梨树县| 措美县| 济宁市| 石柱| 教育| 邓州市| 克山县| 广元市| 陕西省| 扶余县| 宣武区| 韶关市| 潍坊市| 桂东县| 昆明市| 通海县| 东兰县| 多伦县| 横山县| 宝兴县| 丰宁| 台安县| 衢州市| 湖北省| 施秉县| 岫岩| 沁源县|