关于DELPHI DLL传参返回int型问题,在线等待? 我写了个DLL有个函数,function testpchar(a:longint;c:longint;b:pchar):integer;现在要将值写入a,b,返回给调用者pchar型的我可以通过strcopy赋值返回没问题,请问logint(integer)型如何赋值啊? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 var a,c:longint function testpchar(var a:longint;c:longint;b:pchar):integer;调用时:var a,c:longint;begin testpchar(a,c,b);(函数中赋值)执行完 a,c为返回的 楼上说的方法,在delphi中调用是没有一点问题的,但其语言中就有问题了,比如VC中,b我就得strcopy才可以回传成功 用指针就行了 PIntegerPChar不也是指针么 一个道理 pinteger如何赋值呢,有代码么? 示例vc动态调用typedef int(CALLBACK* testpchar_)(DWORD *aaa,char *bbbbb );.......delphi定义function testpchar(a:pinteger;b:pchar):integer;begina^:=1234567;Result:=9000;end; 如何将delphi自带的db文件中的照片信息转化为sql可接受的照片信息 开发网游需求delphi多还是c++多? 用ado如何连接带口令的acces数据库 维护别人的代码,你有没有想过死? 帮帮忙,进来再说!!!!!!!!! (分不多了!)怎么得到当前时间? 各位能不能讲一下学习delphi的心得体会 关于打印报表时如何使结果为0的字段不显示? 线性数学问题,帮帮忙 大家好,想问一下,觉得Pascal比C/C++好用的朋友,来投一票,我可是坚决支持Pascal的!! TCPclient的连接问题 显示服务器文件
调用时:
var
a,c:longint;
begin
testpchar(a,c,b);(函数中赋值)
执行完 a,c为返回的
vc动态调用
typedef int(CALLBACK* testpchar_)(DWORD *aaa,char *bbbbb );
.......delphi定义
function testpchar(a:pinteger;b:pchar):integer;
begin
a^:=1234567;
Result:=9000;
end;