程序为:
library rundll;uses
Windows,
forms,
Messages,
SysUtils;
{$R *.res}procedure showmess; stdcall; export;
begin
application.messagebox('哈哈,可以用了!','提示',64);
end;exports
showmess ;
beginend.用RUNDLL32.exe rundll.dll,showmess执行,可正常运行,点“确定”后就出现RUNDLL32错误
出错的信息:RUNDLL32 在 00de:00000005 的模块
<未知> 中导致无效页错误。
Registers:
EAX=00000000 CS=018f EIP=00000005 EFLGS=00010287
EBX=81dff6f6 SS=0197 ESP=0063fde0 EBP=00000001
ECX=30b472ef DS=0197 ESI=00400000 FS=6fd7
EDX=bffc9a90 ES=0197 EDI=00000f28 GS=0000
Bytes at CS:EIP:
10 00 00 71 01 00 00 65 04 70 00 65 04 70 00 54
Stack dump:
00400000 00000000 81dff6f6 00000001 81e01c4c 00000044 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
library rundll;uses
Windows,
forms,
Messages,
SysUtils;
{$R *.res}procedure showmess; stdcall; export;
begin
application.messagebox('哈哈,可以用了!','提示',64);
end;exports
showmess ;
beginend.用RUNDLL32.exe rundll.dll,showmess执行,可正常运行,点“确定”后就出现RUNDLL32错误
出错的信息:RUNDLL32 在 00de:00000005 的模块
<未知> 中导致无效页错误。
Registers:
EAX=00000000 CS=018f EIP=00000005 EFLGS=00010287
EBX=81dff6f6 SS=0197 ESP=0063fde0 EBP=00000001
ECX=30b472ef DS=0197 ESI=00400000 FS=6fd7
EDX=bffc9a90 ES=0197 EDI=00000f28 GS=0000
Bytes at CS:EIP:
10 00 00 71 01 00 00 65 04 70 00 65 04 70 00 54
Stack dump:
00400000 00000000 81dff6f6 00000001 81e01c4c 00000044 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
解决方案 »
- delphi7打了update后,退出时经常报错,大家是不是都这样啊?
- 如何控制excel单元格中文字的对齐方式:居中、左对齐、右对齐
- 求助:如何将iso-8859-1字符串转化为GB2312??
- DBGrid分组显示?
- 关于TADOStoredProc的CommandText一个问题
- 到哪儿下在delphi7的升级文件
- 我在主窗口里调用一个子窗口,目的是想在主窗口点击时能调用这个子窗口。但不知为什么每次运行时进入的都是子窗口。
- 如何实现文字在不同软件之间的拖放?
- sorry,一个不该在这问的问题。但是很急。
- 各位大哥:请问哪儿有通过ADO操纵数据库的完整程序下载呀。最好是比较精典一点。谢
- 我又有问题了,关于进程的问题呀,大家快来帮忙。很感谢大家,在这里我学到很多!
- 有关进程的问题,大虾请进。。。。。
改為 ShowMessage('XXX');
呢??uses Dialogs;
可正常运行,点“确定”后就还是出现RUNDLL32错误XXSingle(水连天) 我加了还是出错了
export
...
begin
Application.Initialize;
end.
或者,按naughtyboy的建议,应该也可以。简单一点,可以这么写:
MessageBox(nil, '哈哈,可以用了!','提示',MBxxx);
试过了,不行的
2000 用RUNDLL32.exe rundll.dll,showmess执行 出错,
出现“rundll32.exe-应用程序错误”
提示“"0x00000000"指令引用的"0x00000000"内存。该内存不能为"read"。”
98 用RUNDLL32.exe rundll.dll,showmess执行 出错,
出现rundll出错
提示“装载rundll.dll时出错,找不到运行此应用程序所需的某个库文件。”
library mydll;{ 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,Dialogs,
Classes;
procedure showmess; stdcall; export;
begin
MessageDlg('哈哈,可以用了!', mtInformation,[mbOk], 0);
end;
{$R *.res}
exports
showmess ;
beginend.
你那样的,在98一定和我一样的错误,
你的程序在2000不会错,我的也一样
application.handle := handle; 此句可选加入,这样就会使它门处于同一个进程中。
ShowMessage("js;lf");绝对不会报错。
library mydll;{ 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,Dialogs,
Classes;
procedure showmess;
begin
MessageDlg('哈哈,可以用了!', mtInformation,[mbOk], 0);
end;
{$R *.res}
exports
showmess ;
beginend.在98下还是会出错的。
不信你试一下。真搞不明白3721 是怎么搞出来,不会出错的。
郁闷中
DLL连FORM都能SHOW,何况是个消息呢。