Hello,
I am using following code to save a file and a thumbnail image:
ievMain.SaveToFileAll('Page001.afl', -1);
ievMain.LayersCurrent := 0; // Select Background Layer
ShowMessage('Total Layers: ' + IntToStr(ievMain.LayersCount));
ievMain.Proc.SaveUndo();
ievMain.LayersMergeAll();
//Resize merge layer image to a smaller size
ievMain.Proc.Resample(300, -1, TResampleFilter(rfBSpline));
ievMain.IO.SaveToFileJpeg('Page001.jpg');
//Restore the state of ImageEnVect to state before we merged all layers
ievMain.Proc.Undo(False);
ievMain.UnLockUpdate;
ievMain.Update;
ShowMessage('Total Layers: ' + IntToStr(ievMain.LayersCount));
ievMain.MouseInteract := [miMoveLayers, miResizeLayers];
But somehow after merging all files and saving image in jpg ImageEnVect does not seem to be able to Undo the LayersMergeAll. Or am I making any mistake in my code?
Please guide me.
TIA
Yogi Yang