Set Label Text by ID Number?

Started by Valentine, Sat 31/01/2009 21:07:05

Previous topic - Next topic

Valentine

Hi, I want to have some text that alternates between different labels, so to do this easily, I need to use the ID number of the label. However, I'm having trouble setting the text by using the ID number.

I know normally, I would use; MyFirstLabel.Text="Here is some text!";

But using the ID number, I've tried;

Label.0.Text="Here is some text!";
Label[0].Text="Here is some text!";
Label(0).Text="Here is some text!";

Is there a way to make this work? Thanks!

Khris

Use the GUI's Controls array:
gGUI.Controls[0].Text = "...";

SMF spam blocked by CleanTalk