我这样从DLL中导出函数为什么是错的?好向不能识别cdecl external,帮忙指点一下
public
function SEH_INITIALSESSION(HANDLE:Thandle):boolean;cdecl
external 'ShecaCertMgr.dll';
function tform.SEH_INITIALSESSION(HANDLE:Thandle):boolean;
beginend;
public
function SEH_INITIALSESSION(HANDLE:Thandle):boolean;cdecl
external 'ShecaCertMgr.dll';
function tform.SEH_INITIALSESSION(HANDLE:Thandle):boolean;
beginend;
implementation{$R *.dfm}
function SEH_INITIALSESSION(HANDLE:Thandle):boolean;cdecl external 'ShecaCertMgr.dll';
。
。
。implementation{$R *.DFM}
function SEH_InitialSession(HANDLE:Thandle;num1:integer;usertder:pchar;password:pchar;num2:integer;num3:integer;rootcert:pchar;unkonw:pchar):integer;cdecl external 'SafeEngine.dll';procedure TForm1.Button1Click(Sender: TObject);
var
path:string;
cert:string;
hdle:thandle;
begin
path:=extractfilepath(paramstr(0));
if SEH_InitialSession(hdle,2,'D:\wangjian\oracle青浦\CA LICENSE\casureproject\UserKey.key','dd2d8793',0,2,'D:\wangjian\oracle青浦\CA LICENSE\casureproject\rootcert.der','')<>0 then
begin
///terminate application
end;
end;
看看这篇文章吧。应该有帮助的