Author: gamito | Posted on: 7/9/2008 3:18:06 AM | Views : 1195

 Hi,

I'm trying to create a shared folder with a C#/ASP.NET .aspx page.

The code works alright if executed locally, but not through IIS. The folder is created, but not shared.

The code follows my signature.

Any help would be appreciated.

Warm Regards,
M�¡rio Gamito

--

 // create a directory
    Directory.CreateDirectory(@"C:\MyTestShare");
    // Create a ManagementClass object
    ManagementClass managementClass = new ManagementClass("Win32_Share");
    // Create ManagementBaseObjects for in and out parameters
    ManagementBaseObject inParams = managementClass.GetMethodParameters("Create");
    ManagementBaseObject outParams;
    // Set the input parameters
    inParams["Description"] = &quo ...

Go to the complete details ...