This project is read-only.

MSBuild Extension Pack: Convert Virtual Directory to Application

Jan 12, 2011 at 8:37 AM


I need to convert a Virtual Directory which I have added via MSBuild to an application and assign it to my application pool. I have added the Virtual Directory using the following code:


  <WebApplication Include="/IntelliApp">
  <VirtualDirectory Include="/MyVdir">

Name="Default Web Site" 

Please advise whether what I am attempting is feasible.

Jan 12, 2011 at 9:21 AM

Wouldn't you rather AddApplication, e.g.


<Application Include="/MyApp">

Name="Default Web Site" 

Jan 12, 2011 at 10:00 AM

Thanks Mike!

This was exactly the solution I was looking for. Seems as if I was missing Name="Default Web Site" or simply not doing it correctly.

Much appreciated.

Jan 12, 2011 at 10:13 AM

Great. Does this address your other discussion too


Jan 12, 2011 at 10:19 AM

Yes, indeed it does.

Just one last question: I see in a threaded dating July 2009 that you added a work item for deleting an application? Has that been addressed yet?


Jan 12, 2011 at 3:28 PM

I think so


        <!-- Delete Applications -->
        <MSBuild.ExtensionPack.Web.Iis7Application TaskAction="Delete" Website="NewSite" Applications="@(Application)"/>