無法找到指令碼 VBS的指令碼引擎解決辦法

2021-09-06 21:43:56 字數 3277 閱讀 3335

當你在執行一些基於vbs指令碼語言的檔案時,系統可能報錯。這時候可能是你的vbs指令碼服務在登錄檔中出錯了,原因可能是解除安裝或安裝一些**不規範的程式引起的。這裡給出無法找到指令碼引擎"vbscript"的解決方法:

把以下**複製另存為《vbs關聯修復.reg》,雙擊執行即可。

原因是vbs檔案沒有正常關聯,要建立關聯,主要有三個地方要修改。

windows registry editor version 5.00

[hkey_classes_root\.vbs]

@="vbsfile"

[hkey_classes_root\.vbs\persistenthandler]

@=""

[hkey_classes_root\vbsfile]

@="vbscript script 檔案"

"friendlytypename"=hex(2):40,00,25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,\

00,6f,00,6f,00,74,00,25,00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,\

32,00,5c,00,77,00,73,00,68,00,65,00,78,00,74,00,2e,00,64,00,6c,00,6c,00,2c,\

00,2d,00,34,00,38,00,30,00,32,00,00,00

[hkey_classes_root\vbsfile\defaulticon]

@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\

00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,57,00,53,00,\

63,00,72,00,69,00,70,00,74,00,2e,00,65,00,78,00,65,00,2c,00,32,00,00,00

[hkey_classes_root\vbsfile\scriptengine]

@="vbscript"

[hkey_classes_root\vbsfile\scripthostencode]

@=""

[hkey_classes_root\vbsfile\shell]

[hkey_classes_root\vbsfile\shell\edit]

@="編輯(&e)"

[hkey_classes_root\vbsfile\shell\edit\command]

@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\

00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,4e,00,6f,00,\

74,00,65,00,70,00,61,00,64,00,2e,00,65,00,78,00,65,00,20,00,25,00,31,00,00,\

00[hkey_classes_root\vbsfile\shell\open]

@="開啟(&o)"

[hkey_classes_root\vbsfile\shell\open\command]

@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\

00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,57,00,53,00,\

63,00,72,00,69,00,70,00,74,00,2e,00,65,00,78,00,65,00,20,00,22,00,25,00,31,\

00,22,00,20,00,25,00,2a,00,00,00

[hkey_classes_root\vbsfile\shell\open2]

@="在命令提示符中開啟(&w)"

[hkey_classes_root\vbsfile\shell\open2\command]

@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\

00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,43,00,53,00,\

63,00,72,00,69,00,70,00,74,00,2e,00,65,00,78,00,65,00,20,00,22,00,25,00,31,\

00,22,00,20,00,25,00,2a,00,00,00

[hkey_classes_root\vbsfile\shell\print]

@="列印(&p)"

[hkey_classes_root\vbsfile\shell\print\command]

@=hex(2):25,00,53,00,79,00,73,00,74,00,65,00,6d,00,52,00,6f,00,6f,00,74,00,25,\

00,5c,00,53,00,79,00,73,00,74,00,65,00,6d,00,33,00,32,00,5c,00,4e,00,6f,00,\

74,00,65,00,70,00,61,00,64,00,2e,00,65,00,78,00,65,00,20,00,2f,00,70,00,20,\

00,25,00,31,00,00,00

[hkey_classes_root\vbsfile\shellex]

[hkey_classes_root\vbsfile\shellex\drophandler]

@=""

[hkey_classes_root\vbsfile\shellex\propertysheethandlers]

[hkey_classes_root\vbsfile\shellex\propertysheethandlers\wshprops]

@=""

regsvr32 %systemroot%\system32\vbscript.dll

regsvr32 scrrun.dll

regsvr32 cscript.dll

regsvr32 wshom.ocx

regsvr32 wshext.dll

《vbs測試.vbs》能執行這個就證明ok了!

msgbox "hello world!"

指令碼 vbs 有用的指令碼

指令碼 vbs 有用的指令碼 2010年01月15日 顯示系統版本 for each ps in getobject winmgmts root cimv2 win32 operatingsystem instances wscript.echo ps.caption ps.version next...

securecrt的vbs指令碼

vbs檔案內容 language vbscript inte ce 1.0 sub main crt.screen.synchronous true 獲取securecrt物件,定義變數 dim objtab set objtab crt.getscripttab 1.跳轉到相應的目錄,vbcr表示...

多程序的vbs指令碼

資訊 八進位制資訊保安團隊 朋友要刷票,我幫他寫了個刷票的指令碼。但是指令碼只能單執行緒的執行,太慢了,於是我用wmi配合寫了個模擬多執行緒的指令碼。其實是多程序的,呵呵 複製 如下 created 程式設計客棧by 千寂孤城 獲得 wscript.exe 程序的數量 a 0 for each ps...