濮阳杆衣贸易有限公司

主頁 > 知識(shí)庫 > Win7下VHD文件右鍵增強(qiáng)實(shí)現(xiàn)代碼(vbs+注冊表)

Win7下VHD文件右鍵增強(qiáng)實(shí)現(xiàn)代碼(vbs+注冊表)

熱門標(biāo)簽:辦理膠州400電話財(cái)稅 海外美發(fā)店地圖標(biāo)注 前鋒辦理400電話申請 陜西高頻外呼回?fù)芟到y(tǒng)哪家好 外呼營銷下單系統(tǒng) 新密防封卡外呼系統(tǒng)違法嗎 打電話的外呼系統(tǒng)貴不貴 百度地圖標(biāo)注怎么卸載 加盟電銷機(jī)器人好的品牌

1、保存以下代碼到:c:\windows\system32\vdm.vbs

復(fù)制代碼 代碼如下:

Dim Args
Set Args = WScript.Arguments
TranArgs = " "
For i = 0 To Args.Count - 1
 TranArgs = TranArgs """" Args(i) """" " "
Next

If Args(0) > "-hFlag" Then
 If Args(0) > "-hWind" Then
  CreateObject("Shell.Application").ShellExecute "wscript.exe", _
   """" WScript.ScriptFullName """" " -hWind" TranArgs, "", "runas", 1
  WScript.Quit(5)
 Else
  CreateObject("Wscript.Shell").Run "cscript.exe " _
   """" Wscript.ScriptFullName """" Replace(TranArgs, "-hWind", "-hFlag"), 0, TRUE
  WScript.Quit(1)
 End If
Else
 'Add Your Codes
 Dim objShell, objExec
 Set objShell = WScript.CreateObject("Wscript.Shell")
 Set objExec = objShell.Exec("c:\windows\system32\diskpart.exe")

 objExec.StdIn.WriteLine "select vdisk file=""" WScript.Arguments(2) """"

 Select Case Args(1)
  Case "/M"
   objExec.StdIn.WriteLine "attach vdisk"
   objExec.StdIn.WriteLine "exit"
   WScript.Quit(0)

  Case "/D"
   objExec.StdIn.WriteLine "detach vdisk"
   objExec.StdIn.WriteLine "exit"
   WScript.Quit(0)

  Case Else
   'other
   WScript.Quit(0)
 End Select

 WScript.Quit(0)
End If

2、導(dǎo)入注冊表文件:

復(fù)制代碼 代碼如下:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Virtual.Machine.HD\Shell]
@="none"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Virtual.Machine.HD\Shell\Dismount]
@="分離 VHD(D)"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Virtual.Machine.HD\Shell\Dismount\command]
@="\"C:\\windows\\system32\\wscript.exe\" C:\\Windows\\System32\\vdm.vbs /D \"%1\""
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Virtual.Machine.HD\Shell\Mount]
@="掛載 VHD(M)"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Virtual.Machine.HD\Shell\Mount\command]
@="\"C:\\windows\\system32\\wscript.exe\" C:\\Windows\\System32\\vdm.vbs /M \"%1\""
[HKEY_CLASSES_ROOT\.vhd]
@="Virtual.Machine.HD"

文件打包下載:VHD 右鍵增強(qiáng)

標(biāo)簽:阜陽 四平 河南 牡丹江 梅州 咸陽 武威 伊春

巨人網(wǎng)絡(luò)通訊聲明:本文標(biāo)題《Win7下VHD文件右鍵增強(qiáng)實(shí)現(xiàn)代碼(vbs+注冊表)》,本文關(guān)鍵詞  Win7,下,VHD,文件,右鍵,增強(qiáng),;如發(fā)現(xiàn)本文內(nèi)容存在版權(quán)問題,煩請?zhí)峁┫嚓P(guān)信息告之我們,我們將及時(shí)溝通與處理。本站內(nèi)容系統(tǒng)采集于網(wǎng)絡(luò),涉及言論、版權(quán)與本站無關(guān)。
  • 相關(guān)文章
  • 下面列出與本文章《Win7下VHD文件右鍵增強(qiáng)實(shí)現(xiàn)代碼(vbs+注冊表)》相關(guān)的同類信息!
  • 本頁收集關(guān)于Win7下VHD文件右鍵增強(qiáng)實(shí)現(xiàn)代碼(vbs+注冊表)的相關(guān)信息資訊供網(wǎng)民參考!
  • 推薦文章
    繁昌县| 综艺| 桃园县| 平舆县| 玉树县| 靖远县| 抚宁县| 常山县| 敦化市| 景谷| 崇州市| 乐至县| 桂东县| 鸡西市| 彝良县| 金乡县| 和田市| 阜南县| 叶城县| 潼南县| 北宁市| 上杭县| 合江县| 定西市| 青铜峡市| 建德市| 东乌珠穆沁旗| 八宿县| 隆德县| 定西市| 雷波县| 咸宁市| 樟树市| 开鲁县| 香港| 佛山市| 钟祥市| 图木舒克市| 灵台县| 博兴县| 和田市|