不可琢磨的错误!!!!!!!!!!!!!!!!!!

ninestar 2000-07-28 09:02:00
各位大侠:
我有一程序在编译时出现了以下错误信息:
Duplicate resource
请问是何原因???
望不吝赐教,不胜感激!!
...全文
263 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
lotto 2000-08-22
  • 打赏
  • 举报
回复
我也遇到过这种情况,看看你项目中是否有雷同的窗体名吧
bpc 2000-08-07
  • 打赏
  • 举报
回复
这个问题很怪。我遇到过,后来仔细查看代码
发现与自己的程序没有任何关系,居然是DELPHI
默认目录下的UNIT文件捣鬼。。尽量把现在程序
中名为UNIT1,UNIT2之类的改名。。。。。
ninestar 2000-08-07
  • 打赏
  • 举报
回复
可能是你在同一个项目不同的单元中声明了同一各表单名,导致这个错误。
Wingsun 2000-08-02
  • 打赏
  • 举报
回复
有如下两种解决的方法(从别处得来)

Duplicate resource identifier error

Question


Duplicate Resource identifier (c:/delphi/lib/controls.res) ERROR!
I keep getting this... I don't know what's wrong... my project .RES
called (project1.res) doesn't have a single thing that's in common
with controls.res!
This is driving me absolutely nuts... the only thing I ever did was
to delete {$R .res} in the project file but since the, I've replaced
that line...
Answer

A:
Do you have the VCL source? If so, you may want to recompile the whole thing
by adding that directory to your Library path in Environment Options | Library.
I think I had to do this once to get rid of such an error. Another thing to
do is to figure out which $R directive is causing the problem, by removing it
temporarily and recompiling. You can temporarily disable the $R directive by
adding a '.' before the $ (that's one of many ways to do it).

A:
You probably have subclassed one of the built in VCL's. You need to be sure
that the resource identifier for your icon is unique. Just pull it up in any
resource editor and change its number. Then you should be able to rebuild your
library.
gao 2000-07-28
  • 打赏
  • 举报
回复
删除。DSK的文件,
或者你是否本地磁盘上有该程序备份,如有将备份程序的路径改名
w102272 2000-07-28
  • 打赏
  • 举报
回复
重建工程文件。
ninestar 2000-07-28
  • 打赏
  • 举报
回复
我已铲除了所有的res与dcu文件,并且查找项目中的所有文件中的$R指令,没有包含相同资源,问题还是没有解决!
wsf 2000-07-28
  • 打赏
  • 举报
回复
将跟程序有关的res,dcu文件全部铲除,重新builder all,自动生成新的文件
Wingsun 2000-07-28
  • 打赏
  • 举报
回复
看一看你的工程中是否包含的相同的资源多次。
wsf 2000-07-28
  • 打赏
  • 举报
回复
你查看你的代码pas文件,看看是否有两个文件都加入相同的资源文件

5,386

社区成员

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

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