出错信息Resource not found mytxt117
rc中是这样定义的“mytxt1 txt 1.abc”
代码如下(在代码中我加入了{$R a.res}):
procedure TForm1.Button1Click(sender :tobject);
begin
Randomize();
key:=Random(299)+1;
with TResourceStream.Create(HInstance, 'mytxt'+inttostr(key), RT_RCDATA) do
begin
SaveToFile('c:\temp.txt');
Free;
end;
Form1.M1.Lines.LoadFromFile('c:\temp.txt');
Form1.Edit1.Text:=inttostr(key);
rc中是这样定义的“mytxt1 txt 1.abc”
代码如下(在代码中我加入了{$R a.res}):
procedure TForm1.Button1Click(sender :tobject);
begin
Randomize();
key:=Random(299)+1;
with TResourceStream.Create(HInstance, 'mytxt'+inttostr(key), RT_RCDATA) do
begin
SaveToFile('c:\temp.txt');
Free;
end;
Form1.M1.Lines.LoadFromFile('c:\temp.txt');
Form1.Edit1.Text:=inttostr(key);
解决方案 »
- 如何实现所调用资源文件不显示出来?
- 请各位高手提供意见:将VS2003的C#程序迁移到VS2005有必要吗?
- 紧急求助:delphi问题:为什么我的messagebox每次弹出都在屏幕的最右下角?!!在线等
- 很急的一个调用oracle存储过程传出参数的问题,请大家帮忙.
- 搞到熊猫烧香病毒源代码一份~~~~~~爽,待我瞻仰一下~~~~~~~~
- ADOQuery+DBGrideh 的问题
- 菜鸟问个菜问题...
- 这是TDataSource的问题吗?
- 两个listbox,如何从listbox2中删除与listbox1相同的项?
- mdac2.7, delphi6(Enterprise)+service pack2删除数据库有提示 '你的数据集有一个bof或eof为真',不能删除,使用DBGridEh(ehlib 2.3)!?'
- 在程序启动时,自动创建窗体和手动创建窗体有什么不同
- 应该挺简单的, 就是CopyFile的问题
----------
楼主
这个东西是哪里来的?
你在哪里引用了呢?