ImpersonatePrinterClient function (winsplp.h)
ImpersonatePrinterClient resumes impersonation of the client, completing the operation begun by RevertToPrinterSelf.
Syntax
BOOL ImpersonatePrinterClient(
[in] HANDLE hToken
);
Parameters
[in] hToken
Caller-supplied handle to a thread. This parameter must have been previously returned by a call to RevertToPrinterSelf.
Return value
If the operation succeeds, the function returns TRUE. Otherwise the function returns FALSE. The caller can obtain an error code by calling GetLastError (described in the Microsoft Windows SDK documentation).
Remarks
This function must be called after a successful call to RevertToPrinterSelf. It resumes impersonation of the client and cleans up the thread handle.
Requirements
Requirement | Value |
---|---|
Target Platform | Desktop |
Header | winsplp.h (include Winsplp.h) |
Library | Spoolss.lib |
DLL | Spoolss.dll |
See also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for