Delphi6的开发Dll方法在Delphi7下通不过,白思不得其解

activeandbadboy 2003-12-15 09:47:11
使用LoadLibrary加载时总是报错,'Can't Create Application in a Library or a share object'
请指点一下
...全文
39 11 打赏 收藏 转发到动态 举报
写回复
用AI写文章
11 条回复
切换为时间正序
请发表友善的回复…
发表回复
activeandbadboy 2003-12-15
  • 打赏
  • 举报
回复
没有人知道吗
qiume 2003-12-15
  • 打赏
  • 举报
回复
把代码贴出来看一下
nxfbccu 2003-12-15
  • 打赏
  • 举报
回复
你是怎样调用 的?
activeandbadboy 2003-12-15
  • 打赏
  • 举报
回复
是什么问题啊
activeandbadboy 2003-12-15
  • 打赏
  • 举报
回复
我是这样写的试了一个简单的,我的操作系统是2003:
library Project1;

{ Important note about DLL memory management: ShareMem must be the
first unit in your library's USES clause AND your project's (select
Project-View Source) USES clause if your DLL exports any procedures or
functions that pass strings as parameters or function results. This
applies to all strings passed to and from your DLL--even those that
are nested in records and classes. ShareMem is the interface unit to
the BORLNDMM.DLL shared memory manager, which must be deployed along
with your DLL. To avoid using BORLNDMM.DLL, pass string information
using PChar or ShortString parameters. }

uses
SysUtils,
Classes,
Func in 'Func.pas';

{$R *.res}
Exports
ShowMsg;
begin
end.

unit Func;

interface

uses
SysUtils,
Classes,
QDialogs;
Procedure ShowMsg(str:String);StdCall;
implementation
Procedure ShowMsg(str:String);
begin
ShowMessage(Str);
end;
attar 2003-12-15
  • 打赏
  • 举报
回复
reinstall delphi
nxfbccu 2003-12-15
  • 打赏
  • 举报
回复
不会啊,我试了都没问题
activeandbadboy 2003-12-15
  • 打赏
  • 举报
回复
各位大哥,帮忙啊
activeandbadboy 2003-12-15
  • 打赏
  • 举报
回复
编译可以通过,但是一调用就出错,动态和静态调用都出错啊
soundbug 2003-12-15
  • 打赏
  • 举报
回复
把你D6下的哪个DLL工程拿到D7下编译成DLL再试试看
activeandbadboy 2003-12-15
  • 打赏
  • 举报
回复
没有人知道吗

5,391

社区成员

发帖
与我相关
我的任务
社区描述
Delphi 开发及应用
社区管理员
  • VCL组件开发及应用社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧