当前位置: 首页 > 图文教程 > 网络编程 > Javascript > 用jscript实现列出安装的软件列表

Javascript
关于setEndPoint msdn给出的参考
一个不用onmouseup的拖动函数
实现163邮箱的图标功能
javascript 也来玩玩图片预加载
又一个小巧的图片预加载类
使用正则替换变量
JS统计Flash被网友点击过的代码
JS脚本混淆、加密讨论
通过Unicode转义序列来加密,按你说的可以算是混淆吧
javascript之ESC(第二类混淆)
另一种希望别人无法修改js的代码
javascript又一解密过程,推荐的,会这个基本上好多都能解决了
ESC之ESC.wsf可以实现javascript的代码压缩附使用方法
javascript支持区号输入的省市二级联动下拉菜单
一个不错的渐显菜单
javascript之水平横向滚动歌词同步的应用
javascript实现表现、结构、行为分离的选项卡效果!
[全兼容哦]--实用、简洁、炫酷的页面转入效果loing
用js判断浏览器是否是IE的比较好的办法
延时重复执行函数 lLoopRun.js

Javascript 中的 用jscript实现列出安装的软件列表


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-09-12   浏览: 73 ::
收藏到网摘: n/a

Returns a list of software that was installed on a computer
using Windows Installer. This information is then
written to a text file. This script requires both Windows
PowerShell and the corresponding version of
the .NET Framework. For more information on downloading
these items see the Windows PowerShell download page (right).
复制代码 代码如下:

$strComputer = "."
$colItems = get-wmiobject -class "Win32_Product" -namespace "root\CIMV2" `
-computername $strComputer
foreach ($objItem in $colItems) {
write-host "Caption: " $objItem.Caption
write-host "Description: " $objItem.Description
write-host "Identifying Number: " $objItem.IdentifyingNumber
write-host "Installation Date: " $objItem.InstallDate
write-host "Installation Date 2: " $objItem.InstallDate2
write-host "Installation Location: " $objItem.InstallLocation
write-host "Installation State: " $objItem.InstallState
write-host "Name: " $objItem.Name
write-host "Package Cache: " $objItem.PackageCache
write-host "SKU Number: " $objItem.SKUNumber
write-host "Vendor: " $objItem.Vendor
write-host "Version: " $objItem.Version
write-host
}