Image List中图标丢失的问题(100分)

D

dwwang

Unregistered / Unconfirmed
GUEST, unregistred user!
我的程序用ImageList来存储图标,给TreeView使用.
可是当把全部源码拷贝到某些机器上时,发现ImageList
中的图标全都不见了.
Delphi3.0(没有升级到3.01/3.02)

谁能告诉我为什么,怎么解决?
(但不能告诉我用D4 ^_^)
 
>图标全都不见了
您可不可以在图标可见的那些机器上把图标存盘,
拷贝到出问题的机器上, 然后装进去?
 
这个办法未免太"狠毒"了一点吧!:(

其实就是因为这个办法行不通,我才提这个问题的。
因为TreeView是利用ImageIndex的,即使我这么干,
还得记住全部图标的顺序才行。

另外,由于并非每台机器都这样,所以肯定和OS设置有关,
我自己怀疑的最大可能就是那个ComCtl32.dll。但没心思
去试验,想看看大家有没有知道这件事的,关键是"给个说法儿"。
 
dwwang 不用怀疑了, 问题就出在 ComCtl32.dll 的版本上, 使用 IE3.02 以上版
带的 ComCtl32.dll 问题就解决了。不过安装 ComCtl32.dll 也不是很容易的事,
因为 Window 系统正在使用它。MS 有一个程序专门更新 ComCtrl32.dll, 找不到
的话可以退出到 Dos 将新版本的 dll Copy 到 System 目录。
 
这一点你能确认吗?我在一台NT4+SP3的机器上也会
出现这个问题.它的 ComCtl32.dll不如IE3.02新吗?
 
嘿嘿, 再狠毒一些, 程序运行时读取图标文件, 装载进ImageList, :)
 
绝对肯定
 
同意 pegasus 的“再狠毒一些”,我也遇到同样的问题。
最后将 bmp, ico 存入 res, {$R ?.res}, onFormCreate 时装入。
 
pega,yysun:对不起两位了,
我那个程序是一个朋友做的,我根本不知道
每个图标的Index,所以不能改动任何程序。
(当然根本原因是我懒得很!)

我明天给NT4装个IE3.02或comupd看看,
如果搞定了,就给huizhang大虾加分。
如果搞不定,@#$%^&*!
 
呜呜呜!IE302的更新不行呀!

我虽然仍然认为是comctl32.dll的问题,
但只能下载一些别的东东试验了.
 
试一式IE4.0/win98的comctl32.dll

我那么肯定是因为我在D3下写了一个ocx, 用到了ImageList, 装到95机器上不好用,
后来用IE3.02带的comctl32.dll解决的, 次办法14个用户用过都可以.
 
dwwang:
很可能跟您机器的显示器颜色数的设置有关, 如果程序是在24位的基础之上开发的(图标也是用24位颜色的),那么在16位或者256色上可能显示不出来.您在控制面板的显示器里改一改,看是否能够解决.
 
huizhang:

对不起,我主要想解决的是NT4.0下的问题,
而且必须是用一个软件安装的办法(因为是NTFS,自己没法拷了)
我相信IE4可以,但它太大了,而且在NT4.0上装,实在没有那个勇气 :(
因此您如果能告诉我一个像安装程序那样更新Comctl32.dll
的办法就可以了.(不记得ISExpress行不行?)

MicroZeng:
我的问题不仅仅是显示问题,而是双击ImageList时
发现所有图标都没有存在里面.

谢谢大家,我会继续努力的,也希望大家再帮忙.
 
Hi, dwwang, do you want me provide a util that can copy file while
system is using? It can resolve your problem. If you want, I'll go
to program it. I'm sure it will be done within half an hour, :)
 
How about NtSP3?
 
Hi, huizhang:

I had mentioned that I already have SP3 installed but some machine
yet have the problem.

Pega:

I'll be very appreciate if you can make the util for me, :)
However, besides that, I also need to know wich DLL I should use.
That is: which DLL I should directly copy to NT+SP3 that can solve
the problem as well as not affecting any other applications
 
I am not quite sure about NT stuff. But I am sure you can install IE4.0
onto NT4 server, if IIS4.0 is not installed.

May be you can try install IE4.0. After that find out the backup copy
of comctl32.dll and replace it with new copy, then uninstall IE4.0.
In this way, the system will restore the old copy of IE but with new
conctl32.dll. (I preclaim that I will not take any responsibility
about any demage to your system).
 
感谢"会长"大虾的坦诚 :)
这正是我所要避免的--我不能以系统的稳定性为代价
去装任何软件,因此我更需要一个最直接的答案。

我正好要出差一段时间,先就此别过,等回来再详细讨论。

Bye, every one!
 
My program has completed. "ForceMove",
let you set file moving (and replace if target already exists)
nexttime windows restart. So that you can replace system
files that is just in use now, :)

Hehe, you can use this util to replace oldversion of comctrl,
 
EMail me please, pegasus.
 

Similar threads

D
回复
0
查看
2K
DelphiTeacher的专栏
D
S
回复
0
查看
3K
SUNSTONE的Delphi笔记
S
D
回复
0
查看
1K
DelphiTeacher的专栏
D
顶部