[fpc-pascal] Does GetLastError in WinCE work?

epergola epergola at hotmail.com
Fri Oct 30 03:56:52 CET 2009


Hello
I get strange results form GetLasError in WinCe;
something like 1449435930, for example;

I use this:
{$include d:\lazarus\fpc\2.2.4\source\rtl\wince\wininc\coredll.inc} 
function GetLastError:DWORD; external KernelDLL name 'GetLastError'; 

var
 err: dword;

begin
    MutexHandle := CreateMutex(NIL, TRUE, 'xxx');    
    err:= GetCeError;
    if err = ERROR_ALREADY_EXISTS  THEN BEGIN
      SetForegroundWindow(FindWindow('xxx', ''));
      CloseHandle(MutexHandle);
      Application.BringToFront;
    END ELSE BEGIN
      .........
Am I missing something? 
Why do I get those huge values from GetLastError?
Thanks for any help
-- 
View this message in context: http://old.nabble.com/Does-GetLastError-in-WinCE-work--tp26124267p26124267.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.




More information about the fpc-pascal mailing list