But when the threads execute I get an error thrown stating:
Invalid token for impersonation - it cannot be duplicated.
Do you know what is going on here?
I've tried to set the UseCurrentContext but to no avail. Do you know how I can kick off a thread so it carried using the Impersonatoer context it was kick off within?
I'm assuming that I need to pass through the UserToken for the user I'm logged in as I but can't find how to do this anywhere
Hi,
I'm using the STP but wrapped within the following code:
see code here: http://www.codeproject.com/Articles/10090/A-small-C-Class-for-impersonating-a-User?msg=4023519#xx4023519xx
But when the threads execute I get an error thrown stating:
Invalid token for impersonation - it cannot be duplicated.
Do you know what is going on here? I've tried to set the UseCurrentContext but to no avail. Do you know how I can kick off a thread so it carried using the Impersonatoer context it was kick off within?
I'm assuming that I need to pass through the UserToken for the user I'm logged in as I but can't find how to do this anywhere