I'm having some trouble verifying MFC Edit Box data (the box where users type in data). Here's what I need to verify:
- the user types an integer into the edit box, which can be negative
- the verification function should ensure the integer is within a certain range
- if it is an illegal value, it must be changed to some default legal value
The verification function is trivial, but what Edit Box event it is attached to is causing issues. Right now I have the input verification even attached to "EN_CHANGE" but that seems to be causing problems since it runs on every character types. Is there a more appropriate input to attach the verification function to?
Is there a way to not verify the Edit Box data until the user is done inputting? Perhaps by hitting enter or something?