![]() |
Exotic CheckBox
Hi NG
I am making a GUI with some checkboxes and i am VERY focused on making the everyday use of the GUI as uninterrupted as possible e.g. no popup windows with "you can't do this: click ok"-stuff. The GUI is like this: The user chooses some options with by using checkboxes. Some options exclude others or are dependant on others e.g option A can not be choosen if option B is choosen. Further B migth depend on C and so on. The way i handle this is that if i choose A then i do a CheckBox_B.Enable = False. if i click on A one more time (deselct it) then i do a CheckBox_B.Enable = True. In this way the user can never choose A and B at the same time. The user migth think: "why the heck cant i choose B?" and the logical thing might then to click on B - enventhough CheckBox_B.Enable = False. Here is then what i imagine should happen: When the user click on the non-enabled checkbox B, then the backcolor of checkbox A should be changed to red as to indicate the blocking option. Can this be done in ANY way in VBA. I.e i know that somehow the eventlistener stops listening to all the .enabled = false widgets (buttons etc.) in the GUI and thus cant catch a click on checkbox_B Any comments greatly appreciated Mark |
Exotic CheckBox
Mark,
Surely, if you disable it, the checkbox changes to a grey, subdued object, so it is already clear that you cannot click on it? Bullet-proof, hide it, that is set Visible to False. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Mark" wrote in message ... Hi NG I am making a GUI with some checkboxes and i am VERY focused on making the everyday use of the GUI as uninterrupted as possible e.g. no popup windows with "you can't do this: click ok"-stuff. The GUI is like this: The user chooses some options with by using checkboxes. Some options exclude others or are dependant on others e.g option A can not be choosen if option B is choosen. Further B migth depend on C and so on. The way i handle this is that if i choose A then i do a CheckBox_B.Enable = False. if i click on A one more time (deselct it) then i do a CheckBox_B.Enable = True. In this way the user can never choose A and B at the same time. The user migth think: "why the heck cant i choose B?" and the logical thing might then to click on B - enventhough CheckBox_B.Enable = False. Here is then what i imagine should happen: When the user click on the non-enabled checkbox B, then the backcolor of checkbox A should be changed to red as to indicate the blocking option. Can this be done in ANY way in VBA. I.e i know that somehow the eventlistener stops listening to all the .enabled = false widgets (buttons etc.) in the GUI and thus cant catch a click on checkbox_B Any comments greatly appreciated Mark |
Exotic CheckBox
Hi Mark,
In this way the user can never choose A and B at the same time. Use Two Optionbutton instead of two checkbox for this item ( A & B). You may have to use checkbox and optionbutton for other items as per your condition. Regards, Shah Shailesh http://members.lycos.co.uk/shahweb/ (Excel Add-ins) *** Sent via Developersdex http://www.developersdex.com *** Don't just participate in USENET...get rewarded for it! |
Exotic CheckBox
GUI convention: mutually exclusive checkboxes = optionbuttons.
-- "Mark" wrote in message ... Hi NG I am making a GUI with some checkboxes and i am VERY focused on making the everyday use of the GUI as uninterrupted as possible e.g. no popup windows with "you can't do this: click ok"-stuff. The GUI is like this: The user chooses some options with by using checkboxes. Some options exclude others or are dependant on others e.g option A can not be choosen if option B is choosen. Further B migth depend on C and so on. The way i handle this is that if i choose A then i do a CheckBox_B.Enable = False. if i click on A one more time (deselct it) then i do a CheckBox_B.Enable = True. In this way the user can never choose A and B at the same time. The user migth think: "why the heck cant i choose B?" and the logical thing might then to click on B - enventhough CheckBox_B.Enable = False. Here is then what i imagine should happen: When the user click on the non-enabled checkbox B, then the backcolor of checkbox A should be changed to red as to indicate the blocking option. Can this be done in ANY way in VBA. I.e i know that somehow the eventlistener stops listening to all the .enabled = false widgets (buttons etc.) in the GUI and thus cant catch a click on checkbox_B Any comments greatly appreciated Mark |
All times are GMT +1. The time now is 02:53 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com