国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > VBScript > 正文

用vbscript實現隱藏任務欄圖標的腳本

2019-10-26 18:01:35
字體:
來源:轉載
供稿:網友
Message = "To work correctly, the script will close" & vbCR
  Message = Message & "and restart the Windows Explorer shell." & vbCR
  Message = Message & "This will not harm your system." & vbCR & vbCR
  Message = Message & "Continue?"
  X = MsgBox(Message, vbYesNo, "Notice")
  If X = 6 Then
  On Error Resume Next
  Dim WSHShell, n, MyBox, p, t, errnum, vers
  Dim itemtype
  Dim enab, disab, jobfunc
  Set WSHShell = WScript.CreateObject("WScript.Shell")
  p = "HKCU/Software/Microsoft/Windows/CurrentVersion/Policies/Explorer/NoTrayItemsDisplay"
  itemtype = "REG_DWORD"
  enab = "ENABLED"
  disab = "DISABLED"
  jobfunc = "Notification Icons are now "
  t = "Confirmation"
  Err.Clear
  n = WSHShell.RegRead (p)
  errnum = Err.Number
  if errnum <> 0 then
   WSHShell.RegWrite p, 0, itemtype
  End If
  If n = 0 Then
   n = 1
  WSHShell.RegWrite p, n, itemtype
  Mybox = MsgBox(jobfunc & disab & vbCR, 4096, t)
  ElseIf n = 1 then
   n = 0
  WSHShell.RegWrite p, n, itemtype
  Mybox = MsgBox(jobfunc & enab & vbCR, 4096, t)
  End If
  Set WshShell = Nothing
  On Error GoTo 0
  For Each Process in GetObject("winmgmts:"). _
   ExecQuery ("select * from Win32_Process where name='explorer.exe'")
   Process.terminate(0)
  Next
  MsgBox "Finished." & vbcr & vbcr , 4096, "Done"
  Else 
  MsgBox "No changes were made to your system." & vbcr & vbcr, 4096, "User Cancelled"
  End If
發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表

圖片精選

主站蜘蛛池模板: 西平县| 东宁县| 武强县| 三河市| 西乌珠穆沁旗| 太仓市| 沛县| 南昌县| 花莲县| 桐庐县| 田东县| 夏河县| 旬阳县| 赤水市| 韶山市| 济阳县| 曲沃县| 合阳县| 竹山县| 本溪| 象山县| 锡林郭勒盟| 瓦房店市| 福安市| 泽普县| 黎平县| 四会市| 祁连县| 白水县| 扎囊县| 尉犁县| 南雄市| 沅陵县| 永顺县| 恭城| 苏尼特右旗| 开原市| 兴化市| 东台市| 肇源县| 嫩江县|