TImageEnMView.MultiSelectedImages
Declaration
property MultiSelectedImages[index: Integer]: Integer;
Description
Returns the index of all selected images, where MultiSelectedImages[0] returns the index of the first selected image, MultiSelectedImages[1] returns the second, etc.
Note:
◼Use
MultiSelectedImagesCount to determine how many images are selected
◼Items will be returned by
MultiSelectedImages in index order. If you want the order they were selected, add
iemoDontSortMultiSelection to
MultiSelectionOptions◼This property is valid even if
multiple selection is not enabled (i.e. returning
SelectedImage).
◼To select multiple items, use
SelectedImage// Replace all selected images with 'new.jpg'
for i := 0 to ImageEnMView1.MultiSelectedImagesCount - 1 do
begin
selIdx := ImageEnMView1.MultiSelectedImages[ i ];
ImageEnMView1.SetImageFromFile( selIdx, 'new.jpg' );
end;
// Rotate selected images right (90° clockwise)
for i := 0 to ImageEnMView1.MultiSelectedImagesCount - 1 do
begin
selIdx := ImageEnMView1.MultiSelectedImages[ i ];
bmp := ImageEnMView1.GetTIEBitmap( selIdx );
bmp.Rotate( 270 );
ImageEnMView1.ReleaseBitmap( selIdx, True );
end;
ImageEnMView1.Update();
// Get filenames of all selected files
lbxFilenames.clear;
for i := 0 to ImageEnMView1.MultiSelectedImagesCount - 1 do
begin
selIdx := ImageEnMView1.MultiSelectedImages[ i ];
lbxFilenames.Items.Add(ImageEnMView1.ImageFileName[selIdx]);
end;
// Access files in the order that user selects them
ImageEnMView1.MultiSelectionOptions := ImageEnMView1.MultiSelectionOptions + [iemoDontSortMultiSelection];
for i := 0 to ImageEnMView1.MultiSelectedImagesCount - 1 do...
See Also
◼MultiSelectedImagesCount◼MultiSelectedImagesList◼IsSelected◼MultiSelectionOptions