DirectoryEntry root = new DirectoryEntry(@"IIS://localhost/W3SVC");
string PInfo = "";
foreach (string elmentName in root.Properties.PropertyNames)
{
PropertyValueCollection valueCollection = root.Properties[elmentName];
for (int i = ; i < valueCollection.Count; i++)
{
PInfo += elmentName + "[ " + i.ToString() + "] = " + valueCollection[i].ToString() + "\r\n";
}
}

PInfo的结果是:

KeyType[ 0]   = IIsWebService
SslUseDsMapper[ 0]   = False
LogFileDirectory[ 0]   = C:\inetpub\logs\LogFiles
LogPluginClsid[ 0]   = {FF160663-DE82-11CF-BC0A-00AA006111E0}
AppPoolId[ 0]   = DefaultAppPool
IIs5IsolationModeEnabled[ 0]   = False
DontLog[ 0]   = False
DirBrowseFlags[ 0]   = 1073741854
DefaultDoc[ 0]   = Index.aspx,Default.htm,Default.asp,index.htm,index.html,iisstart.htm,default.aspx
AuthFlags[ 0]   = 1
AnonymousUserName[ 0]   = IUSR
AspDiskTemplateCacheDirectory[ 0]   = C:\inetpub\temp\ASP Compiled Templates
HttpErrors[ 0]   = 401,*,FILE,C:\inetpub\custerr\zh-CN\401.htm
HttpErrors[ 1]   = 403,*,FILE,C:\inetpub\custerr\zh-CN\403.htm
HttpErrors[ 2]   = 404,*,FILE,C:\inetpub\custerr\zh-CN\404.htm
HttpErrors[ 3]   = 405,*,FILE,C:\inetpub\custerr\zh-CN\405.htm
HttpErrors[ 4]   = 406,*,FILE,C:\inetpub\custerr\zh-CN\406.htm
HttpErrors[ 5]   = 412,*,FILE,C:\inetpub\custerr\zh-CN\412.htm
HttpErrors[ 6]   = 500,*,FILE,C:\inetpub\custerr\zh-CN\500.htm
HttpErrors[ 7]   = 501,*,FILE,C:\inetpub\custerr\zh-CN\501.htm
HttpErrors[ 8]   = 502,*,FILE,C:\inetpub\custerr\zh-CN\502.htm
SSIExecDisable[ 0]   = False
AccessSSLFlags[ 0]   = 0
NTAuthenticationProviders[ 0]   = Negotiate,NTLM
WebSvcExtRestrictionList[ 0]   = 0,*.exe
WebSvcExtRestrictionList[ 1]   = 0,*.dll
WebSvcExtRestrictionList[ 2]   = 1,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,ASP.NET v4.0.30319,ASP.NET v4.0.30319
WebSvcExtRestrictionList[ 3]   = 1,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,ASP.NET v4.0.30319,ASP.NET v4.0.30319
WebSvcExtRestrictionList[ 4]   = 1,C:\Windows\system32\inetsrv\asp.dll,1,ASP,Active Server Pages
WebSvcExtRestrictionList[ 5]   = 1,C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\isapi\_vti_aut\author.dll,1,Windows SharePoint Services V3,Windows SharePoint Services V3
WebSvcExtRestrictionList[ 6]   = 1,C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\isapi\_vti_adm\admin.dll,1,Windows SharePoint Services V3,Windows SharePoint Services V3
WebSvcExtRestrictionList[ 7]   = 1,C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\isapi\shtml.dll,1,Windows SharePoint Services V3,Windows SharePoint Services V3
WebSvcExtRestrictionList[ 8]   = 1,C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\isapi\owssvr.dll,1,Windows SharePoint Services V3,Windows SharePoint Services V3
WebSvcExtRestrictionList[ 9]   = 1,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,ASP.NET v2.0.50727,ASP.NET v2.0.50727
AccessFlags[ 0]   = 513
ScriptMaps[ 0]   = .rules,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1
ScriptMaps[ 1]   = .xoml,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1
ScriptMaps[ 2]   = .asp,C:\Windows\system32\inetsrv\asp.dll,5,GET,HEAD,POST
ScriptMaps[ 3]   = .cer,C:\Windows\system32\inetsrv\asp.dll,5,GET,HEAD,POST
ScriptMaps[ 4]   = .axd,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 5]   = .aspx,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 6]   = .rules,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1
ScriptMaps[ 7]   = .xoml,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1
ScriptMaps[ 8]   = .ashx,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 9]   = .asmx,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 10]   = .rem,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 11]   = .soap,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 12]   = .svc,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1
ScriptMaps[ 13]   = .xamlx,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 14]   = .aspq,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 15]   = .cshtm,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 16]   = .cshtml,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 17]   = .vbhtm,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 18]   = .vbhtml,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 19]   = .axd,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 20]   = .aspx,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 21]   = .rules,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1
ScriptMaps[ 22]   = .xoml,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1
ScriptMaps[ 23]   = .ashx,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 24]   = .asmx,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 25]   = .rem,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 26]   = .soap,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 27]   = .svc,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1
ScriptMaps[ 28]   = .xamlx,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 29]   = .aspq,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 30]   = .cshtm,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 31]   = .cshtml,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 32]   = .vbhtm,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 33]   = .vbhtml,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 34]   = .svc,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1
ScriptMaps[ 35]   = .axd,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 36]   = .aspx,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 37]   = .ashx,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 38]   = .asmx,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 39]   = .rem,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 40]   = .soap,C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 41]   = .stm,C:\Windows\system32\inetsrv\ssinc.dll,5,GET,POST
ScriptMaps[ 42]   = .shtm,C:\Windows\system32\inetsrv\ssinc.dll,5,GET,POST
ScriptMaps[ 43]   = .shtml,C:\Windows\system32\inetsrv\ssinc.dll,5,GET,POST
ScriptMaps[ 44]   = .,C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ScriptMaps[ 45]   = .,C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet_isapi.dll,1,GET,HEAD,POST,DEBUG
ApplicationDependencies[ 0]   = Active Server Pages;ASP
DoDynamicCompression[ 0]   = True
HttpCustomHeaders[ 0]   = X-Powered-By: ASP.NET

DirectoryEntry_Properties属性的遍历(win2008)的更多相关文章

  1. DirectoryEntry_Properties属性的遍历(win2003)

    DirectoryEntry root = new DirectoryEntry(@"IIS://localhost/W3SVC"); string PInfo = "& ...

  2. [转] JavaScript中的属性:如何遍历属性

    在JavaScript中,遍历一个对象的属性往往没有在其他语言中遍历一个哈希(有些语言称为字典)的键那么简单.这主要有两个方面的原因:一个是,JavaScript中的对象通常都处在某个原型链中,它会从 ...

  3. 【转载】JavaScript中的属性:如何遍历属性

    转载自:http://www.cnblogs.com/ziyunfei/archive/2012/11/03/2752905.html 在JavaScript中,遍历一个对象的属性往往没有在其他语言中 ...

  4. JavaScript中对象的属性:如何遍历属性

    for/in 语句循环遍历对象的属性. js中获取key得到某对象中相对应的value的方法:obj.key js中根据动态key得到某对象中相对应的value的方法有二: 一.var key = & ...

  5. VAD树结构体的属性以及遍历

    Windows内核分析索引目录:https://www.cnblogs.com/onetrainee/p/11675224.html VAD树的属性以及遍历 前面学习过的PFNDATABSAE是管理物 ...

  6. js 属性的遍历

    引自:http://es6.ruanyifeng.com/#docs/object 属性的遍历 ES6 一共有5种方法可以遍历对象的属性. (1)for...in for...in循环遍历对象自身的和 ...

  7. Iterator遍历器 调用Symbol.Iterator属性,遍历器对象。

    Iterator实现原理 创建一个指针对象,指向当前数据结构的起始位置.也就是说,遍历器对象本质上,就是一个指针对象. 第一次调用指针对象的next方法,可以将指针指向数据结构的第一个成员. 第二次调 ...

  8. JavaScript 对象属性的遍历

    ES6一共有5种方法可以遍历对象的属性. (1)for...in for...in循环遍历对象自身的和继承的可枚举属性(不含Symbol属性). (2)Object.keys(obj) Object. ...

  9. js解析多层嵌套的json,取出所有父元素属性和遍历所有子元素

    已知一个多层嵌套的json,取出所有父元素和子元素的id值 思路:因为不知道到底嵌套了多少层,递归有可能造成栈溢出.查询时间特别久的问题 所以先查询一次,判断是否有子节点,如果有,取出子节点并到父节点 ...

随机推荐

  1. Solr建立索引时,过滤HTML标签

    原文地址  http://www.joyphper.net/article/201306/188.html 1.在数据库的读取文件data-config.xml 中的entity 标记里边添加 tra ...

  2. shiro实战系列(四)之配置

    Shiro之配置 Shiro 被设计成能够在任何环境下工作,从最简单的命令行应用程序到最大的的企业群集应用.由于环境的多样性,使得许多配置机制适用于它的配置. 一. 许多配置选项 Shiro的Secu ...

  3. 【转】为什么volatile不能保证原子性而Atomic可以?

    直接上好文链接!!! 为什么volatile不能保证原子性而Atomic可以?

  4. ceph 池管理

    存储池的概念:比如有10个1T的硬盘,作为一个集群,那就可以在这个集群里划分几个池,给不同的组件使用 问题描述: 删除pool的时候提示下面的错误: ceph osd pool delete test ...

  5. jqgrid 宽度自适应

    当jqgrid所在操作区宽度大于了给各列设置宽度之和时,此时表格的宽度未铺满操作区,效果不理想 此时,可以通过配置宽带自适应来现实表格内容自动铺满. 配置属性 shrinkToFit:ture 若要启 ...

  6. linux系统分析工具续-SystemTap和火焰图(Flame Graph)

    本文为网上各位大神文章的综合简单实践篇,参考文章较多,有些总结性东西,自认暂无法详细写出,建议读文中列出的参考文档,相信会受益颇多.下面开始吧(本文出自 “cclo的博客” 博客,请务必保留此出处ht ...

  7. rpm yum apt-get redhat centos ubuntu

    rpm是由红帽公司开发的软件包管理方式,使用rpm我们可以方便的进行软件的安装.查询.卸载.升级等工作.但是rpm软件包之间的依赖性问题往往会很繁琐,尤其是软件由多个rpm包组成时.Yum(全称为 Y ...

  8. odoo tree视图 当页不弹窗显示方法

    <xpath expr="//tree" position="attributes"> <attribute name='editable'& ...

  9. 【js】某字符串多次替换

    eg:  var str="icon icon-1chkedchkedchked"; var strNew=str.replace(new RegExp("chked&q ...

  10. vue-cli 动态绑定图片失败

    1.template 中引用图片,第一个为固定路径,第二个为动态绑定路径 eg: <img src="XXXXXX.png" alt=""> < ...