Input Mask for control on form

I am trying to see if I can create an input mask for a textbox on my form. Right now I have this control set up as a number datatype. The numbers are 4 decimal places out. I want to see if there's a way I can create an input mask to also add 2 text characters at the end. The two text characters would either be "PC" or "FT".

The user will enter values like this. These are just examples below. The numbers can be any value. I want to do this to keep the syntax the same for all my users. Some like to enter things differently so I want to uniform this control. So if a user only enters .010 PC, I want that to change to .0100/PC. Or if a user enters .01 /FT, I want that to change to .0100/FT. Would the input mask be the most logical place to set this up?

.0100/PC
.0100/FT
.0250/FT
.0250/PC
LVL 1
Lawrence SalvucciInformation Technology ManagerAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

NorieVBA ExpertCommented:
What's the data type of the underlying field?
0
Lawrence SalvucciInformation Technology ManagerAuthor Commented:
It's a text field
0
Gustav BrockCIOCommented:
You could place small group right of the textbox with two radio buttons to select either "PC" or "FT".
Then, When saving the records, set the table field to:

Me!YourTextbox.Value & "/" & IIf(Me!YourOptionGroup.Value, 1, "PC", "FT")

Open in new window

Or even better, if "PC" and "FT" is some kind of type, create a separate field to hold this.

/gustav
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

Dale FyeCommented:
Personally, I would advise against this; you are violating one of the basics of relational database design (First Normal Form).  You should never put more than one piece of information in a field, you obviously have two (a number and a text string).  I would recommend two controls, a text box for the numeric value, and a combo for the two character string.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Lawrence SalvucciInformation Technology ManagerAuthor Commented:
I was going to create a separate field to hold the FT or PC values but I would rather it be in the same field as the numeric portion. I was just looking for a way to keep everything in one control without having to use helper controls. Doesn't sound like this is the best solution so I will go with using a separate field to store the text portion of the value. If I keep them in separate controls then I will change the datatype to numeric so the syntax will always be the same regardless of what they type in for numbers/decimal values. Thank you for all the help and input!
0
Dale FyeCommented:
glad to help.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.