[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Type 61
- Date: Tue, 6 May 2003 09:35:33 +0200
- Date: Tue, 6 May 2003 02:34:09 -0600
- From: "Herr von Grabe" <vgrabe@xxxxxxxxxxxxxxxx>
- Subject: Type 61
Hallo!
I have the following problem:
I am trying to use the type 61 dll routine.The simple example Extdll.dll routine runs but my own Delphi source code seems not to work. I have tried the following source code (which seems to be going around here):
library EXTDLLP;
{$R *.RES}
{$D+; L+}
uses
SysUtils,
Classes;
type
chr280 = array[0..280] of char;
realarray100 = array[1..100] of single;
realarray4 = array[1..4] of single;
doublearray100 = array[1..100] of double;
intarray15 = array[1..15] of integer;
procedure EXTDLL (var Spass:chr280; var SArrayPass:realarray100; var SimArray:realarray4;
var XIn:doublearray100; XOut:doublearray100; var T, DTDT:realarray100;
var Par:realarray100; var Info:intarray15; var ICtrl:intarray15);export;stdcall;
begin
XOut[1] := XIn[1] * XIn[2];
SPass := 'Gruß aus der externen DLL!';
end;
exports
EXTDLL;
begin
end.
It does not work, and I think this is because it is not an Extdll.dll file created but an EXTDLLP.dll file. That is not exactly the required name for the file. So I tried the following:
library EXTDLL;
{$R *.RES}
{$D+; L+}
uses
SysUtils,
Classes;
type
chr280 = array[0..80] of char;
realarray100 = array[1..100] of single;
realarray4 = array[1..4] of single;
doublearray100 = array[1..100] of double;
intarray15 = array[1..15] of integer;
procedure EXTDLLU (var Spass:chr280; var SArrayPass:realarray100; var SimArray:realarray4;
var XIn:doublearray100; XOut:doublearray100; var T, DTDT:realarray100;
var Par:realarray100; var Info:intarray15; var ICtrl:intarray15);export;stdcall;
begin
XOut[1] := XIn[1] * XIn[2];
SPass := 'Gruß aus der externen DLL!';
end;
exports
EXTDLLU name 'EXTDLL';
begin
end.
That is not working either! Is there anything wrong and I am just too blind to see?? What about the extdll.lib file? If it is deleted even the original example does not work anymore! Do I have to change this file as well??
Hoping for help,
Joern
-------------------------------------------------
Dipl.- Ing. M.Sc. Jörn von Grabe
Michael Lange
Beratender Ingenieur VBI
Wilmersdorfer Straße 145-146
10585 Berlin
Telefon: +49 (30) 347998-0
Telefax: +49 (30) 347998-33
E-Mail: vGrabe@michael-lange.de
Internet: www.michael-lange.de
-------------------------------------------------