c#创建的类库(dll)能在delphi中调用吗?
答案:2 悬赏:80 手机版
解决时间 2021-04-07 08:33
- 提问者网友:人生佛魔见
- 2021-04-06 08:53
c#创建的类库(dll)能在delphi中调用吗?
最佳答案
- 五星知识达人网友:蕴藏春秋
- 2021-04-06 10:12
C中的动态库中定义
extern int PASCAL NET_Create( int NetType, const char *strIP, int port );
delphi中
implementation下面声明
function NET_Create(NetTyp:Integer; const strIP:string; port:Integer ):integer; stdcall; external NETDLL name 'NET_Create';
{$R *.dfm}
procedure ……
var a:integer;
begin
……
a:= NET_Create(1,'192.168.1.0',9652); //直接用,但是声明必须和动态库中的结构一样。
……
end;
end.
extern int PASCAL NET_Create( int NetType, const char *strIP, int port );
delphi中
implementation下面声明
function NET_Create(NetTyp:Integer; const strIP:string; port:Integer ):integer; stdcall; external NETDLL name 'NET_Create';
{$R *.dfm}
procedure ……
var a:integer;
begin
……
a:= NET_Create(1,'192.168.1.0',9652); //直接用,但是声明必须和动态库中的结构一样。
……
end;
end.
全部回答
- 1楼网友:雪起风沙痕
- 2021-04-06 10:42
以找另一台的电脑上去复制下这个缺失的文件,看看能否解决问题
或者你可以尝试使用腾讯电脑管家来修复缺失dll文件
具体方法是,打开腾讯电脑管家--电脑诊所--软件问题--丢失.dll 文件--一键修复--完成
如果还是解决不了,去脚本之家下一个文件直接复制进去就能搞定了
如果找不到,还可以下载一个dx修复工具3.0增强版,去修复一下
我要举报
如以上回答内容为低俗、色情、不良、暴力、侵权、涉及违法等信息,可以点下面链接进行举报!
点此我要举报以上问答信息
大家都在看
推荐资讯