InputMask for string in ComboBox

MHM

Registered User.
Local time
Today, 22:08
Joined
Mar 15, 2000
Messages
101
(Really struggled hours, yet: is there really no way??)

Why isn't it possible setting up an inputMask for a 2-column string-cmoboBox? In any other case - like textBox - it's no problem, but is there really no way getting through a "not in list"-abort-message??

Explanation:
My combo has 2 columns, containing an ID and a string-field with column-widths 0 and 2cm (ID not visible), getting data from a table.
I wanted to set up an inputMask in order to be able to insert numbers like 1.234.567.890 with _.___.___.___ . Access accepts this inputMask (as "0.000.000.000" or "A\.AAA\.AAA\.AAA", but then it produces combo_notInList(NewData, Response), because the data already existing is like 1.234.567.890 as string(!, containing the dots), which is not the same like the "NewData", which comes as Long.

After having added Format(NewData,"#,##0") to the RowSource-table it is in there, but even Response=acDataErrAdded does not let the code run beyond this (nor does changing NewData). Instead the user is stopped by warning message and has to push {ESC} to get out of this.
The "NewData" has alread been added well, it's in the drop-down, but putting in any number using the inputMask (instead of choosing an entry in drop-down) will always lead to an error.

Is there a way getting through this?
Can a text-inputMask be combined with this comboBox?

Our customer is still interested in getting a better solution - therefor I'd appreciate help a lot.
Thanks!
 
What about converting the string to an integer or # variable?? would the inputmask accept it then?? you would have to remove the dots before you could convert it though.

im not even sure if this would work or not.

- Topher
 
Thanks, Topher!

I've constantly be considering changing field type - but my customer needs these numbers including their format - which disables any type-conversion.

Do inputMasks work at strings like this??
 

Users who are viewing this thread

Back
Top Bottom