码迷,mamicode.com
首页 > Windows程序 > 详细

WinServer2008下通过powershell获取IIS等角色功能列表,保存至txt

时间:2016-07-21 00:33:12      阅读:363      评论:0      收藏:0      [点我收藏+]

标签:

Set objShell = CreateObject("WScript.Shell")

strCommondLine = "powershell.exe"

app = objShell.Run(strCommondLine)

objShell.AppActivate app

WScript.Sleep 100

strCommond = "Import-Module ServerManager {ENTER} Get-WindowsFeature|out-file IISServiceList.txt -Encoding UTF8 {ENTER} Exit {ENTER}"

objShell.SendKeys strCommond

WScript.quit

WinServer2008下通过powershell获取IIS等角色功能列表,保存至txt

标签:

原文地址:http://www.cnblogs.com/zzhua/p/5690071.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!