Results 1 to 5 of 5
  1. #1
    Silver Lounger
    Join Date
    Jan 2002
    Posts
    1,615
    Thanks
    0
    Thanked 1 Time in 1 Post

    Customized Imput Mask (2002)

    Hi,

    I have a form where the user needs to enter the invoice number. The format for the invoice number is XXXXX - XXXXXXX. The format is text. The "x" are numbers and can vary in size. There is a space between the x and the hyphen (on both sides of the hyphen). I'd like to set up and imput mask so the user has not option re the spaces on either side of the hyphen and/or can't forget to put the hyphen in.

    Is this possible especially with the x varying in number?

    Thanks,
    Leesha

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Customized Imput Mask (2002)

    Input masks work best for strings of fixed length. The nearest you could get would be
    <code>99999 - 99999;0;_</code>
    where you should use as many 9s as needed for the longest invoice number, but it wouldn't handle spaces correctly.

  3. #3
    Silver Lounger
    Join Date
    Jan 2002
    Posts
    1,615
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Customized Imput Mask (2002)

    Hi Hans,

    Is there any other approach you'd suggest so that the spaces aren't an issue?

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Customized Imput Mask (2002)

    Use two separate number fields, one for the first part and the other for the second part. You can use a calculated expression in a query or on forms/reports, for example in a query:

    Invoice: [FirstPart] & " - " & [SecondPart]

    where FirstPart and SecondPart are the separate fields.

  5. #5
    Silver Lounger
    Join Date
    Jan 2002
    Posts
    1,615
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Customized Imput Mask (2002)

    WOW!! I was actually considering doing that but figured there might be another way. I think I might be getting this LOL!

    Thanks,
    Leesha

Posting Permissions

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