I have created a web setup for my web service application and managed to deploy successfully. However, the web setup will always create my virtual directory under the inetpub\wwwroot directory (which happens to be in my C-drive).
Is there anyway I can make the web setup create the virtual
directory in another location, eg, d-drive as my client have wwwroot in d drive. I have tried to remove the installation address step of the web setup, but it still default to inetpub\wwwroot.
Here’s some code I wrote which will give you an idea of how I create a virtual directory. I’ve just included the code as I wrote it, so there are a couple of leaps of faith in there. But hopefully the inbound parameters are obvious (although note that the method expects that you know the ID of the web site). Check out also the second method (called by the first) – these two methods in combination will allow you to access an existing site’s existing virtual directory, and to set various properties including the “Path” property.
Hope this helps you along the way…
Also…
Just noticed the hungarian notation right at the top – Cringe!