ACC: Input Mask with Numeric Literals Inserts Incorrectly

ID: Q119706


The information in this article applies to:


SYMPTOMS

Novice: Requires knowledge of the user interface on single-user computers.

If you create an input mask that contains a numeric literal for a field, and then enter a number that is part of that numeric literal in the field, the number is not entered in the field unless you type it twice.


CAUSE

Microsoft Access determines that the character you type matches the literal that you defined in the input mask, and moves you to the next non-literal position in the input mask.


RESOLUTION

In the form containing the field with the input mask, specify the following macro in the field's OnEnter property setting:


   SendKeys Action
   -------------------

      Keystrokes: {F2}
      Wait: No 


STATUS

Microsoft has confirmed this to be a problem in Microsoft Access versions 2.0, 7.0, and 97.


MORE INFORMATION

Steps to Reproduce Problem


  1. Create a new table with one field with a Number data type.


  2. Set the field's InputMask property to:

    "19"## (make sure to include the quotation marks)


  3. Save the table, and then view it in Datasheet view.


  4. Type 89 in the field. Note that the field displays "1989," as is expected.


  5. In the next cell, type 94. Note that "19 4" is displayed in the cell. The 9 you entered is not displayed.



REFERENCES

For more information about the SendKeys action, search the Help Index for "SendKeys action," or ask the Microsoft Access 97 Office Assistant.

Additional query words: data entry format


Keywords          : TblOthr 
Version           : 2.0 7.0 97
Platform          : WINDOWS 
Issue type        : kbbug 

Last Reviewed: April 6, 1999