Thanks Eric, SetAll() will be a simple way to do it. I'm wondering about the overhead if it is called each time the class is initiated ( in the init event). Should one think about figuring out a scheme to allow calling SetAll() only once after all instances are loaded or just allow it to happen repeatedly? This would be easy to do if everything were hand coded but I am hoping the class will be self contained and functional as soon as it is dropped on a form using the Form Designer.
Thanks again, Joe
On Mon, Jul 15, 2024 at 8:29 AM Eric Selje Eric@saltydogllc.com wrote:
This might be a use case for the SetAll() method. You can set a property (e.g. Enabled) of all instances of a class in one swoop.
See The Hacker's Guide https://hackfox.github.io/section4/s4g394.html for details.
Eric
On Fri, Jul 12, 2024 at 6:17 PM Joe Yoder joe@wheypower.com wrote:
First of all - Thanks very much for all the help in my quest to really understand classes. I am finally at the place that I can make a change
and
expect it to work. BTW = I was able to run the code version of my class and find my issues.
I will have multiple instances of a container class on a form. All the containers will be disabled until clicked on. How do I make sure all
other
instances are set to disabled when a click in one instance is detected? Can this be done in the container class or do I need to add a form
method?
Can this happen automatically when an instance of the class is added to a form?
Thanks in advance, Joe
--- StripMime Report -- processed MIME parts --- multipart/alternative text/plain (text body -- kept) text/html
[excessive quoting removed by server]