Message 1 of 4
Option Button Validate
Not applicable
06-04-2003
06:41 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
In a dialog I have 4 option buttons that when changed show stored values in a number
of different controls. If the user changes a value in one of the other controls and then
tries to change option buttons without hitting apply, I want to prompt them with a
messagebox.
Maybe some of the problems I am having are because this is in a addin dll ?? but if I
use a normal option button the validate sub fires but the click event never does. (just
like it works if you are stepping through code using the validate sub). If I change the
option buttons to graphical buttons then it works every time except the first.
The form loads, I edit a textbox which sets a Boolean to notify the validate that
something has changed, but then when I click a different option button the text change
event fires again??, and the validate doesn't. After that first time it works right.
Is there a better way to do what I want. If I put the code in the Mouse down event for
the option buttons is there any way to cancel the click event for it?
I imagine I could do it in the click event but it would take all kinds of Booleans and
checks and storing the old button name etc.
--
Kent
Assistant Moderator
Autodesk Discussion Forum Moderator Program
of different controls. If the user changes a value in one of the other controls and then
tries to change option buttons without hitting apply, I want to prompt them with a
messagebox.
Maybe some of the problems I am having are because this is in a addin dll ?? but if I
use a normal option button the validate sub fires but the click event never does. (just
like it works if you are stepping through code using the validate sub). If I change the
option buttons to graphical buttons then it works every time except the first.
The form loads, I edit a textbox which sets a Boolean to notify the validate that
something has changed, but then when I click a different option button the text change
event fires again??, and the validate doesn't. After that first time it works right.
Is there a better way to do what I want. If I put the code in the Mouse down event for
the option buttons is there any way to cancel the click event for it?
I imagine I could do it in the click event but it would take all kinds of Booleans and
checks and storing the old button name etc.
--
Kent
Assistant Moderator
Autodesk Discussion Forum Moderator Program