TImageEnMView.BeginSelectImages
Declaration
procedure BeginSelectImages();
Description
Call BeginSelectImages() and
EndSelectImages to select multiple images without refreshing the component's state.
Generally this will speed up the selection process.
Note:
BeginSelectImages will reset the existing selection
// select the first 100 images
ImageEnMView1.BeginSelectImages();
for i := 0 to 99 do
ImageEnMView1.SelectedImage := i;
ImageEnMView1.EndSelectImages();
// Save only checked images
wasMS := ImageEnMView1.EnableMultiSelect;
try
ImageEnMView1.LockUpdate();
ImageEnMView1.EnableMultiSelect := True;
ImageEnMView1.Deselect();
ImageEnMView1.BeginSelectImages();
for i := 0 to ImageEnMView1.ImageCount - 1 do
if ImageEnMView1.Checked[i] then
ImageEnMView1.SelectedImage := i;
ImageEnMView1.EndSelectImages();
ImageEnMView1.MIO.SaveToFile( 'C:\Images.tiff', ioUnknown, True );
finally
ImageEnMView1.EnableMultiSelect := wasMS;
ImageEnMView1.UnlockUpdate();
end;