Or in the coming February release, you can just use:
iemv_OUT.Clear();
iemv_OUT.MIO.LoadFromFile(FullPathIN);
if posIn >= 9998 then
posIn := iemv_OUT.ImageCount;
var x := (if posIn > 0 then posIn - 1 else posIn + 1);
ww := iemv_OUT.ImageWidth[ x ];
hh := iemv_OUT.ImageWidth[ x ];
iemv_OUT.InsertImage( posIn, ww, hh, ie24RGB, clWhite );
Nigel
Xequte Software
www.imageen.com