Hi. I use my NT account (login and password in web.config) to do impersonation. The application basically reads a directory on a shared drive on the network. When I switch to a different NT account, however, (by changing the login and password information in web.config) I get the error:
An error occurred while attempting to impersonate. Execution of this request cannot continue.
What are the things I should check? Both NT accounts have full permissions on the shared directory. Should both accounts be defined on the IIS server?
I have in web.config the following:
<connectionStrings>
<add name="FolderLogin" connectionString="myloginid;mypassword;mydomain" />
</connectionStrings>
which the application reads into strLogin, strDomain, and strPassword and runs the following:
// obtains user to ...
Go to the complete details ...