I'm trying to connect to a DLL supplied by someone else. The only instructions they give is:

Public Class FanSelection
Member of optimiser namespace

Public Shared Function seekImpeller(ByVal impCode As String) As String
Member of optimiser.FanSelection

I have written the following program:

unit multiunit;

interface

uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls;

type
TForm1 = class(TForm)
Edit1: TEdit;
Button2: TButton;
procedure Button2Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;

var
Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Button2Click(Sender: TObject);
type
TseekImpellerFunc = function (var impcode: string) : string; stdcall;

var
Handle : cardinal;
seekImpellerFunc : TseekImpellerFunc;
impcode:string;

begin
impcode:= Edit1.Text;
Handle := LoadLibrary('C:\acedevelop\multiwing DLL\optimiser.dll');
if Handle <> 0 then
begin
@seekImpellerFunc := GetProcAddress(Handle, 'seekImpeller');
if Assigned (seekImpellerFunc) then
ShowMessage('dynamic: ' + seekImpellerFunc(impcode))
else
ShowMessage('"seekImpellerFunc" function not found');
FreeLibrary(Handle);
end
else
begin
ShowMessage('optimizer.dll not found / not loaded');
end;
end;

end.

The program runs and gives this message;
seekImpellerFunc" function not found'


Can someone see a problem in the code?

Thanks in advance.