EVW_NUMERIC

This switch allows you to also accept "events" consisting of a string of numeric digits followed by <ENTER> .  This is particularly useful when migrating from text-mode (or power-user) environments where users are accustomed to selecting fields or menu options by keying in the corresponding number and hitting <ENTER>.  When you start adding clickable controls to such screens, you may want to replace the "Enter Field #"  prompt with an EVENTWAIT operation, allowing the user the choice of  either clicking on a control (possibly generating an exitcode or a keyboard string simulating what the user could have typed to make that selection), or just typing the desired option # and hitting Enter.

Note that these numeric keyboard "events" are returned to the calling program with exitcode set to 0, and ctlid set to the numeric value entered.  Since the returned ctlid may not have anything to do with a valid control ID, take care not to pass the value back as input to a subsequent EVENTWAIT operation (or else it will probably abort with exitcode 99, meaning invalid control ID.)  In other words, after interpreting the returned ctlid, set it back to either 0 or to the ID or a valid control on which you want to place focus for the next EVENTWAIT.

See EVW_RAW for a similar option.