快精灵印艺坊 您身边的文印专家
广州名片 深圳名片 会员卡 贵宾卡 印刷 设计教程
产品展示 在线订购 会员中心 产品模板 设计指南 在线编辑
 首页 名片设计   CorelDRAW   Illustrator   AuotoCAD   Painter   其他软件   Photoshop   Fireworks   Flash  

 » 彩色名片
 » PVC卡
 » 彩色磁性卡
 » 彩页/画册
 » 个性印务
 » 彩色不干胶
 » 明信片
   » 明信片
   » 彩色书签
   » 门挂
 » 其他产品与服务
   » 创业锦囊
   » 办公用品
     » 信封、信纸
     » 便签纸、斜面纸砖
     » 无碳复印纸
   » 海报
   » 大篇幅印刷
     » KT板
     » 海报
     » 横幅

取得服务器上用户组列表脚本之VBS版

\\\'groups.vbs
\\\'它原来的显示方法是wsh的方式,往往要多屏显示,而且不能保存结果
\\\'我将之改成IE显示的方式,用起来方便些.:)

On Error Resume Next
\\\'dim wshell
dim ie,doc

set ie = createobject("internetexplorer.application")
ie.navigate "about:blank"
ie.visible = true

set doc = ie.document

CRLF=CHR(13)+CHR(10)
DomainString =inputbox("请输入一个域名:")
msgbox "域名是:"&DomainString

write "<Table border=1 cellpadding=4 width=90% bgcolor=ffffcc><TR Align=Center><TD valign=top> <B><Font
Size=5 Color=Blue>"&UCASE(DomainString)&"内的所有组的列表</B></Font></td></tr></table>"
doc.title=UCASE(DomainString) & " - 组"

Set DomainObj = GetObject("WinNT://" & DomainString)
tmp= DomainObj.MinPasswordLength \\\'verify this is a valid domain
if err.number<>0 then
write "<Font Color=Red> There was an error connecting to " & domainname & "</Font>!<br>"
set ie=Nothing
wscript.quit
end if

DomainObj.Filter = Array("group")
strInfo="<Table border=0 cellpadding=5><TR><TD><B><Font Size=3>组名</Font></B></TD><TD><B><Font Size=3>描述
</Font></B></TD></TR>"
ie.StatusText="正在收集信息,请稍候......"
For Each GroupObj In DomainObj
If GroupObj.Class = "Group" Then
strInfo=strInfo&"<TR><TD><B><Font Size=3>"&GroupObj.Name&"</Font></B></TD><TD><B><Font
Size=3>"&GroupObj.Description&"</Font></B></TD></TR>"
End If
Next
set DomainObj = Nothing
set GroupObj = Nothing
strInfo=strInfo & "</Table>"
write strInfo & "<br>"

write "<font size=1><I>" & Now & "</I></Font>"

set ie=Nothing
set doc=Nothing
wscript.quit

\\\'******************
sub write(str)
doc.body.insertAdjacentHTML "beforeend", str
end sub
返回类别: 教程
上一教程: 用ASP实现支持附件的EMAIL系统
下一教程: 制作我们自己的EBAY(拍卖系统)(1)

您可以阅读与"取得服务器上用户组列表脚本之VBS版"相关的教程:
· 取得服务器上用户组列表的脚本之ASP版
· 在ASP中取得服务器网卡的MAC地址、DNS地址等网络信息
· 无刷新随时取得当前服务器时间用户登陆时间,在线时间,空闲时间并自动退出的例子
· ASP跨服务器上传文件完美解决
· 跨服务器上传文件完美解决
    微笑服务 优质保证 索取样品