EricDraven
Programmer
Hi all,
I want to be able to access a components property by its number. For example, I have 20 images all visible := false;
I also have a random number X. What I want to do is display the TImage like so.
Image2.Visible := True;
Would be
TImage(X).Visible := True;
This doesnt work though. I have tried using,
(Components[X] as TImage).Visible := True;
however this doesnt display every possible image. Im guessing this is because there could be other components with a number in the range 1 - 20 before the images. Anybody have any ideas??? Arte Et Labore
I want to be able to access a components property by its number. For example, I have 20 images all visible := false;
I also have a random number X. What I want to do is display the TImage like so.
Image2.Visible := True;
Would be
TImage(X).Visible := True;
This doesnt work though. I have tried using,
(Components[X] as TImage).Visible := True;
however this doesnt display every possible image. Im guessing this is because there could be other components with a number in the range 1 - 20 before the images. Anybody have any ideas??? Arte Et Labore