James Chapman-Smith wrote:
Hi David,
What do you mean by incredibly slow? How many buttons are we talking about?
I just did a test with 1000 buttons and it took 3.47 milliseconds. With 5000
buttons it was 16.78 milliseconds.
Did I miss something?
Cheers.
James.
I'm with you James.
I usually do something like (psuedoish)
foreach (Control c in this.Controls)
{
Button b = c as Button;
if (b != null)
{
if (b.Name.ToString().ToLower().Trim() = "foo") b.Text = "bar";
}
}
I have no issues with speed. I also do this recursively with no issues
for controls in controls/etc.
--
Les Hughes
l...@datarev.com.a,u