I come from Germany because the bad English.
My problem is that I PicShow not with the Random wants.
- Code: Select all
// Selects randomly an image from the list and loads it in to PicShow
procedure TMainForm.LoadNextImage;
var
Index: Integer;
begin
LoadedImage := '';
if Pictures.Count > 0 then
begin
repeat
Index := Random(Pictures.Count);//What must I change there ???
until (Pictures.Count <= 1) or (ShowingImage <> Pictures[Index]);
LoadedImage := Pictures[Index];
PicShow.Picture.LoadFromFile(PicturesPath + '\' + LoadedImage);
end;
end;
Thank you
Uwe