<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.iis.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:cs="http://blogs.iis.net/"><channel><title>Configuration &amp; Scripting</title><link>http://forums.iis.net/1034.aspx</link><description>Use this forum to get assistance with understanding, editing, or using the IIS metabase including automating with ADSI or WMI</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>Re: Create a simple IIS Clone (winform)</title><link>http://forums.iis.net/thread/1909978.aspx</link><pubDate>Fri, 10 Jul 2009 23:10:22 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1909978</guid><dc:creator>davcox</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1909978.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1034&amp;PostID=1909978</wfw:commentRss><description>&lt;p&gt;Still working on this?&lt;/p&gt;
&lt;p&gt;IIS configuration only knows about web sites and virtual directories, it does not have a list of all the physical folders underneath a particular website or virtual directory.&amp;nbsp; You&amp;#39;ll have to write separate code that for each virtual directory would open&amp;nbsp;the folder, and then list the child folders (and do this recursively). &lt;/p&gt;
&lt;p&gt;Dave &lt;/p&gt;</description></item><item><title>Create a simple IIS Clone (winform)</title><link>http://forums.iis.net/thread/1903869.aspx</link><pubDate>Fri, 15 May 2009 15:21:12 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1903869</guid><dc:creator>Paolo72</dc:creator><slash:comments>0</slash:comments><comments>http://forums.iis.net/thread/1903869.aspx</comments><wfw:commentRss>http://forums.iis.net/commentrss.aspx?SectionID=1034&amp;PostID=1903869</wfw:commentRss><description>&lt;p&gt;Hi, i&amp;#39;m trying to create a simple windows form tree (c# 3.5) like IIS that show Sites/Virtual Directory/Applications/Folder/Files.&lt;br /&gt;I have to do this for Win2003/Vista/Win2008/Win7 (iis 6 and 7).&lt;br /&gt;&lt;br /&gt;I have some problems to show all folder.&lt;br /&gt;For example this simple code not discover &lt;b&gt;physical &lt;/b&gt;directories.&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;static void Main(string[] args)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; DirectoryEntry dir = new DirectoryEntry(&amp;quot;IIS://Localhost/W3SVC/1/Root&amp;quot;);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Expand(dir);&lt;br /&gt;}&lt;br /&gt;private static void Expand(DirectoryEntry entry)&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; foreach (DirectoryEntry child in entry.Children)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Console.WriteLine(&amp;quot;{0} [{1}]&amp;quot;, child.Name, child.SchemaClassName.ToString());&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Expand(child);&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;My idea is:&lt;br /&gt;1) list all site&lt;br /&gt;2) on &amp;quot;beforeExpand&amp;quot; event create nodes for each virtual directory&lt;br /&gt;3) on &amp;quot;beforeExpande&amp;quot; of a virtual directory create nodes for virtual directories and folder and files&lt;br /&gt;&lt;/p&gt;&lt;p&gt;&lt;br /&gt;Can you help me?&lt;br /&gt;&lt;/p&gt;</description></item></channel></rss>