Hi Bruce,
You must have done something wrong. I built a very simple demo with Delphi 2010 on Windows 7 that loads images into TIEImageList and adds a description of the file to a TListView. When a ListView item is selected, the image is loaded from the in-memory TIEImageList and is displayed nicely in ImageEnView.
I do not get any exceptions when the TIEImageList is freed.
I built a couple of example applications that store screen captures, and files opened from disk for my EBook as well. These do not have any of the problems you reported.
The problem may be this:
ImageList.AppendImageRef(TIEBitmap.Create(ImageEnView1.IO.IEBitmap), iFileName);
where TIEBitmap.Create(ImageEnView1.IO.IEBitmap) creates the imagelist bitmap.
Change AppendImageRef method from
ImageList.AppendImageRef(ImageEnView1.IEBitmap, Path);
to
ImageList.AppendImageRef(TIEBitmap.Create(ImageEnView1.IO.IEBitmap), Path);
and I suspect your app will work as expected and the exceptions will probably not occur as well. The bitmaps will be stored in memory.
TIEImageList is very nice because if memory is exceeded by the images the bitmaps are cached to disk sutomatically.
William Miller
Adirondack Software & Graphics
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html