DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/index.php)
-   Pascal and Delphi (http://www.daniweb.com/forums/forum124.html)
-   -   Pascal DLL (http://www.daniweb.com/forums/thread161066.html)

|brando Dec 6th, 2008 5:10 pm
Pascal DLL
 
Im trying to compile a DLL to use with mIRC (chat client with an integrated language)

library dll;

uses
    SysUtils,
    Classes,
    Windows;

function Test(mWnd, aWnd : HWND; data, parms : PChar; show, nopause : boolean) : integer; stdcall;
var
  s : string;
begin
    s := 'Hello World';
    strcopy(data, PChar(s));
    result := 3;
end;

begin
end.

exports Test;
Compiler: Dev-Pascal 1.9.2

Im getting one error:
- Fatal: Can't find unit CLASSES

I can compile if i remove Classes, but then i can't access the function im trying to export (Test)

Can anyone suggest a solution?

LizR Dec 7th, 2008 5:25 am
Re: Pascal DLL
 
Im surprised that classes would stop you seeing the exported function, but then Im not up on dev-pascal.


All times are GMT -4. The time now is 12:15 pm.

Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC