Thorny said:
[blue] . . . each instituion has its own [purple]account number format[/purple].[/blue]
The combobox rowsource needs to be based on a table that includes a field for the account format (say [blue]
AcctFmt[/blue]). This makes the format easily available thru the combo (this column can be hidden).
Since your talking format (a bit more to check than just length), the [blue]
AcctFmt[/blue] field could comprise indicators for validating.
As an example, using N for numbers, L for letters here's what [blue]
AcctFmt[/blue] would like for the following account numbers:
[tt]Account Number 465-T2054A-01
AcctFmt NNN-LNNNNL-NN
Account Number CZ 020567NB744-05A
AcctFmt LL NNNNNNLLNNN-NNL
Account Number 4567089458990087744
AcctFmt NNNNNNNNNNNNNNNNNNN[/tt]
You'll have to get those formats in the field, but once your done [blue]you'll be able to validate length and format.[/blue]
Use the [blue]On KeyDown[/blue] event of the [blue]account number[/blue] textbox for a character by character validation and the ability to block keys.
[blue]Your Thoughts? . . .[/blue]
See Ya! . . . . . .
Be sure to see thread181-473997