Hola de nuevo.
Sigo sin poder reproducir el error, por lo que intuyo que se trata de la versión de S.O., de Delphi o de algún programa externo que esté infirirendo.
El código que usé para la prueba es muy simple:
Código Delphi
[-]
...
type
TForm1 = class(TForm)
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
public
end;
var
Form1: TForm1;
function MessageBoxTimeOut(hWnd: HWND; lpText: PChar; lpCaption: PChar;
uType: UINT; wLanguageId: WORD; dwMilliseconds: DWORD): Integer; stdcall;
implementation {$R *.dfm}
const
MB_TIMEDOUT = 32000;
function MessageBoxTimeOut; external user32 name 'MessageBoxTimeoutA';
procedure TForm1.Button1Click(Sender: TObject);
var
R : Integer;
begin
R := MessageBoxTimeout(Handle,
'This box will close after 5 seconds.',
'Testing',
MB_SETFOREGROUND OR MB_SYSTEMMODAL OR
MB_ICONINFORMATION OR MB_OKCANCEL,
0,
5000);
if R = IDOK then
ShowMessage('Ok')
else if R = IDCANCEL then
ShowMessage('Canceled')
else if R = MB_TIMEDOUT then
ShowMessage('TimedOut');
end;
end.
La prueba fué realizada en
Delphi 7 corriendo sobre
Windows 7 64 bits, te adjunto los fuentes + ejecutable para que puedas cotejarlo con lo que te está dando el error.
Saludos