How can I cancel an UltraNumericEditor value changed event?
Are you changing the grid filter in the ValueChanged of the UltraNumericEditor? Why not just keep track of the value that the user is currently filtering by, and when the value has changed, you can prompt the user if the want to apply that filter or revert back to the original value? I don't think there's an event to cancel the update of the value, so this may be your best bet.
-Matt
The editor control is not within the grid. It acts as a filter for the grid. So, if a user attempts to change the numericeditor when the grid data has been modified I want to confirm the user wants to discard the grid changes before continuing.
I'm still not quite sure about how you have your controls set up. Is the UltraNumericEditor used as an EditorControl within the grid? Is it bound somehow? The standalone control does not have any events that will tell you when the value is being updated so that you can cancel it; if it is bound, this is not something that the editor would have any control over anyway. You could try looking at the Parse and Format events of the DataBinding if you need to manipulate this. Otherwise I need more details of what you're doing so that I can try to suggest a different alternative.
I tried this, but it doesn't behave as expected. It only fires when focus to the control is lost. So, if a user presses up three times, the control is dirty, the grid (to which it is managing criteria data) is either not updated (which looks wierd to the user), or refreshed with the new data, which is what I hope to prevent.
I need an event that fires when the control data changes that allows me to cancel the data change event.
You should use the BeforeExitEditMode instead, which will prevent the user from updating the value if it doesn't fall within your criteria. If it's being changed by something in your code, there is no event for this, but since it's in your code, you should be able to set a condition on whether or not to set the value.