HOWTO: Use the MaskedEdit Control for Currency Format (126676)
The information in this article applies to:
- Microsoft Visual Basic Professional Edition for Windows 3.0
This article was previously published under Q126676 SUMMARY
The maskededit control requires that you enter a number for each of the
pound sign (#) character place holders and enter a space for each of the
ampersand (&) place holders. The control tests each character you enter to make sure it matches the specified mask. This is inconvenient for currency format. For example, if the mask is #####.##, you'd have to enter 00012.25;
and if the Mask is &&&&#.##, you'd have to enter four spaces and then 12.25
(as in " 12.25").
This article shows by example how to gain the flexibility of entering any
number. The application uses the period (.) to define the decimal point,
and right aligns the number to the decimal point. Then you can enter the
pennies.
Modification Type: | Minor | Last Reviewed: | 2/24/2005 |
---|
Keywords: | kbhowto KB126676 |
---|
|