>couldn't formname.SetAll(,,,),with appropriate parameters work as well?
Yup. Sure. Like I mentioned that everyone else had said.
But like Barbara said in her reply, SetAll() only works on the
class, not the
baseclass. So if your form has all subclasses on it, and several different subclasses of the textbox, but you want to change the property of everything whose baseclass is textbox, that requires you to hard-code a series of commands which reference all your subclasses of textbox, like:
Form.SetAll("Enabled", .F., "MyBaseText")
Form.SetAll("Enabled", .F., "MyPhoneText")
Form.SetAll("Enabled", .F., "MyDateText")
Because the loop I suggested is a more generic way of getting to everything of a certain
base class, I thought it made more sense for a class method than hard-coded references to all the subclasses of a base class used on a form class.
Of course this is only my opinion.
Cheers,
Rich.
Rich Addison, Micro Vane, Inc., Kalamazoo, MI
Relax, don't worry, have a homebrew.
- Charlie Papazian, The New Complete Joy of Home Brewing