Hanuj Reddy
Hanuj Reddy

Reputation: 21

Changing local path in the default website of IIS through .NET code

I want to change Local path in the Home Directory tab of the Default Website in IIS, programmatically from the C# code.

Upvotes: 1

Views: 2503

Answers (2)

Davide Piras
Davide Piras

Reputation: 44605

There are managed APIs to deal with IIS, see John's asnwer here: IIS API - Create virtual directories? for an example and also here: Creating a new website programmatically on IIS using ASP.NET and C# the body of the method: CreateWebsite.

both are examples and should be adapted but a good starting point to show you how to interact with IIS from .NET / C#

Upvotes: 0

Related Questions