Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Feb 2002
    Location
    Albuquerque, NM, USA
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Edit Mask Message (acc2000)

    When a field is keyed that does not satisfy the Input Mask the following sample message is displayed:
    "The value you entered isn't appropriate for the input mask 'I0000009999' specified for this field"

    Is there a way to modify the text dynamically for this message as it applies to a specific field?

    I set the input mask depending upon the value of another control and would like to customize the message for the specific edit mask similar to how the validation text can be set for a validation rule on a control.

    For example, client X requires and Id field to begin with the letter "I", followed by from 6 to 10 digits. The edit mask for the Id control is set to "I0000009999" upon selecting client X in a combo box. When the Id value is not correctly entered I would like to display the message "Client X requires their Employee Id to begin with the letter 'I' followed by from 6 to 9 digits" instead of the canned text.

    Any ideas would be appreciated,

    Thanks,

    Warren

  2. #2
    Gold Lounger
    Join Date
    Jun 2001
    Location
    Crystal Beach, FL, Florida, USA
    Posts
    3,436
    Thanks
    1
    Thanked 34 Times in 34 Posts

    Re: Edit Mask Message (acc2000)

    I think the only thing you can do is pretty much lose the input mask altogether, then test the user's input in your control's BeforeUpdate event. This way you can put in your own messages when a test fails.
    Mark Liquorman
    See my website for Tips & Downloads and for my Liquorman Utilities.

  3. #3
    New Lounger
    Join Date
    Feb 2002
    Location
    Albuquerque, NM, USA
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Edit Mask Message (acc2000)-MULTI-Re: Edit Mask Message

    Thanks Mark for your response. I had thought of just coding my own edit for the BeforeUpdate event, but decided that was a bad idea due to the coding involved, reinventing wheels, etc.

    I was finally able to get into MSKB and found an article (Q210343) that uses the form's OnError event to trap this error and suppress the standard message and it works quite well. I tried the error trap before, but did not know of the acDataErrContinue response value so initially it did not work.

    Thanks again,

    Warren

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •