小编Ser*_*gio的帖子

Delphi 2010:EOleSysError'类型不匹配'调用ActiveX控件

我有这个C ActiveX API(没有源只是二进制文件):

// \param a [out] Variant holding a byte array 
// \param b [out] Reference to a longlong (Signed 64-bit)
// \param c [out] Reference to a short
short foo(variant* a, longlong* b, short* c);
Run Code Online (Sandbox Code Playgroud)

它在C#中运行良好:

//auto-generated import:   
short foo(ref object a, ref long b, ref short c);

test {
 object a=null;
 long b=0;
 short c=0;
 foo(a,b,c); => OK 
}
Run Code Online (Sandbox Code Playgroud)

Delphi 2010中的NOK(注意{?? Int64} OleVariant由Delphi导入工具添加):

//auto-generated import:
function foo(var a: OleVariant; 
             var b: {??Int64}OleVariant; 
             var c: Smallint): …
Run Code Online (Sandbox Code Playgroud)

delphi activex

5
推荐指数
1
解决办法
852
查看次数

标签 统计

activex ×1

delphi ×1