Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to subclassing option group
Message
From
26/08/2006 07:33:35
 
 
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01148773
Message ID:
01148788
Views:
19
No, you can't. They're defined in parent class and are unchangeable. What can you do, instead, is to define the base class with 0 buttons and add them in subclass. I'm not sure if this fits you (I guess you have some code in your option buttons).

I'd define a optionbutton class and use MemberClass and MemberClassLibrary properties of the OptionGroup class to point to the correct optionbutton class. In optionbutton class I'd enter a This.Parent.SomeMethod(This), then in OptionGroup class I'd enter the code that executes when a specific optionbutton is checked (the optionbutton was passed as parameter, so I'll know what to do).

I hope I was clear enough. If not, please come back with a message.
Thank you.

>Hi Jim,
>
>I have create a subclass of the option group in the class designer. When I then add that subclass to the form in the form designer I cant change the names of the option buttons in the group.
Grigore Dolghin
Class Software.
Previous
Reply
Map
View

Click here to load this message in the networking platform