Does anyone know how to control IIS (7.0+) from C#.NET?
I want to create and FTP site and then create an FTP users which has read and write access on different folders?
Is there some sort of library I can user for this?
Thank you
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You should be able to use the IIS ADSI Provider Interfaces to do this.
Here’s a blog post with a sample for reading configuration: HOWTO: Enumerate IIS website and ftpsite configuration (VBScript using ADSI)
You should be able to adjust this sample to instead write the information you need and then just convert the script to C#.
This KB article should show you how to use ADSI from C#: How to access ADSI objects in Visual C#