Ver Mensaje Individual
  #4  
Antiguo 20-07-2004
NeWNeO NeWNeO is offline
Miembro
 
Registrado: ago 2003
Posts: 35
Reputación: 0
NeWNeO Va por buen camino
Post Modificación

He modificado String por PChar y si que se envia el resultado, pero una vez gestionado saca un error, pero esta vez en lugar de en el dll en el archivo exe...

Código Delphi [-]

procedure TForm1.RunClick(Sender: TObject);
var
h: THandle;
title: function(Sender: TObject):PChar; stdcall;
begin
 DLLControl1.LibDir := GetCurrentDir;
 h := DLLControl1.AllocateDLL('dllfile.dll');
 if h  = 0 then showmessage('File not found');
 if DLLControl1.CheckFunction(h,'Test',@title) then showmessage(Title(Self))  else showmessage('Process not found');
 DLLControl1.DeallocateDLL(h);
end;

Gracias

Última edición por NeWNeO fecha: 20-07-2004 a las 17:33:38.
Responder Con Cita