Гость
Целевая тема:
Создать новую тему:
Автор:
Форумы / ASP.NET [игнор отключен] [закрыт для гостей] / DirectoryEntry / 3 сообщений из 3, страница 1 из 1
08.07.2005, 15:51
    #33157283
man_78
Участник
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
DirectoryEntry
Не могу саздать обьект. подскажите как сделать правельно!!!
Писал так:

DirectoryEntry entry=new DirectoryEntry(sPatch);
DirectoryEntries myEnries=entry.Children;

DirectoryEntry myDirectoryEntry=myEnries.Add"Sample",
entry.SchemaClassName);
myDirectoryEntry.CommitChanges();

Вылетает ошибка:
General access denied error

Exception Details: System.UnauthorizedAccessException: General access denied error

ASP.NET is not authorized to access the requested resource. Consider granting access rights to the resource to the ASP.NET request identity. ASP.NET has a base process identity (typically {MACHINE}\ASPNET on IIS 5 or Network Service on IIS 6) that is used if the application is not impersonating. If the application is impersonating via <identity impersonate="true"/>, the identity will be the anonymous user (typically IUSR_MACHINENAME) or the authenticated request user.

To grant ASP.NET write access to a file, right-click the file in Explorer, choose "Properties" and select the Security tab. Click "Add" to add the appropriate user or group. Highlight the ASP.NET account, and check the boxes for the desired access.
...
Рейтинг: 0 / 0
08.07.2005, 19:02
    #33157654
Hratchia
Участник
Скрыть профиль Поместить в игнор-лист Сообщения автора в теме
DirectoryEntry
дай юзеру ASPNET права в АД


Posted via ActualForum NNTP Server 1.2
...
Рейтинг: 0 / 0
11.07.2005, 13:48
    #33159344
DirectoryEntry
Или
Код: plaintext
DirectoryEntry entry=new DirectoryEntry(sPatch, sLogin, sPassword);
где sLogin и sPassword соответственно логин и пароль такого юзера который имеет на это право
...
Рейтинг: 0 / 0
Форумы / ASP.NET [игнор отключен] [закрыт для гостей] / DirectoryEntry / 3 сообщений из 3, страница 1 из 1
Найденые пользователи ...
Разблокировать пользователей ...
Читали форум (0):
Пользователи онлайн (0):
x
x
Закрыть


Просмотр
0 / 0
Close
Debug Console [Select Text]