/// Sets the last-error code for the calling thread..
/// <param name="dwErrorCode">The last-error code for the thread.</param>
static extern void SetLastError(uint dwErrCode);
Declare Function SetLastError Lib "kernel32.dll" (ByVal dwErrCode As Integer) As Integer
Tips & Tricks:
Call SetLastError(0) at the beginning of your function if you'll use GetLastError.
Please add some!
Alternative Managed API:
Do you know one? Please contribute it!
The SetLastError API
4/11/2011 3:33:35 PM - -18.104.22.168
Please edit this page!
Do you have...
- helpful tips or sample code to share for using this API in managed code?
- corrections to the existing content?
- variations of the signature you want to share?
- additional languages you want to include?
Select "Edit This Page" on the right hand toolbar and edit it! Or add new pages containing supporting types needed for this API (structures, delegates, and more).