Text Box with single Letter only

  • Thread starter Thread starter Jim
  • Start date Start date
J

Jim

I have a text box on a form where I need to have only one letter F, J, or
I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?
Thanks
Jim
 
Set a validation rule that will allow only one letter and only one of these
letters:

Like "[fji]"
 
If it were me, I would make it a combo box.

In the ROW SOURCE TYPE I would enter "Value List"
In the ROW SOURCE I would enter "F;J;I"
I would set the LIMIT TO LIST to "Yes"

Hope that helps.


I have a text box on a form where I need to have only one letter F, J, or
I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?
Thanks
Jim
 
Jim said:
I have a text box on a form where I need to have only one letter F,
J, or I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?

You could set a validation rule for the textbox, or create a combobox using
a value list as the row source, and set Limit To List to true.
 
Hi Rick
Looks a good idea, however, I can't seem to make it work
correctly. It says not validated!
Any ideas
Jim
 
Hi Ken
Entered that in the val rule but doesn't like it.
Does it need something else?
Jim

Ken Snell said:
Set a validation rule that will allow only one letter and only one of these
letters:

Like "[fji]"


--
Ken Snell
<MS ACCESS MVP>

Jim said:
I have a text box on a form where I need to have only one letter F, J, or
I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?
Thanks
Jim
 
"Doesn't like it" means what -- you get an error message? and if yes, what
does it say? Did you enter it in the properties for the control on the form?
Or somewhere else?

--
Ken Snell
<MS ACCESS MVP>

Jim said:
Hi Ken
Entered that in the val rule but doesn't like it.
Does it need something else?
Jim

Ken Snell said:
Set a validation rule that will allow only one letter and only one of these
letters:

Like "[fji]"


--
Ken Snell
<MS ACCESS MVP>

Jim said:
I have a text box on a form where I need to have only one letter F,
J,
or
I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?
Thanks
Jim
 
Jim said:
Hi Rick
Looks a good idea, however, I can't seem to make it work
correctly. It says not validated!
Any ideas
Jim

Jim, the Row Source should be "F";"J";"I"
 
Hi Ken
I took the long way round and created a table with F J and I
in the rows and attached it to a combo box, which works fine.
Not so efficient though I suspect.
I see that Joans solution works well on my backup file.
Many thanks for your help
Jim

Ken Snell said:
"Doesn't like it" means what -- you get an error message? and if yes, what
does it say? Did you enter it in the properties for the control on the form?
Or somewhere else?

--
Ken Snell
<MS ACCESS MVP>

Jim said:
Hi Ken
Entered that in the val rule but doesn't like it.
Does it need something else?
Jim

Ken Snell said:
Set a validation rule that will allow only one letter and only one of these
letters:

Like "[fji]"


--
Ken Snell
<MS ACCESS MVP>

I have a text box on a form where I need to have only one letter F, J,
or
I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?
Thanks
Jim
 
OK - just to let you know, the solution that I posted worked fine in my
ACCESS 2002 setup as the validation rule for a control on a form.


--
Ken Snell
<MS ACCESS MVP>

Jim said:
Hi Ken
I took the long way round and created a table with F J and I
in the rows and attached it to a combo box, which works fine.
Not so efficient though I suspect.
I see that Joans solution works well on my backup file.
Many thanks for your help
Jim

Ken Snell said:
"Doesn't like it" means what -- you get an error message? and if yes, what
does it say? Did you enter it in the properties for the control on the form?
Or somewhere else?

--
Ken Snell
<MS ACCESS MVP>

Jim said:
Hi Ken
Entered that in the val rule but doesn't like it.
Does it need something else?
Jim

Set a validation rule that will allow only one letter and only one of
these
letters:

Like "[fji]"


--
Ken Snell
<MS ACCESS MVP>

I have a text box on a form where I need to have only one letter
F,
J,
or
I
(in capitals) entered and I want no other letter or letters inserted.
How do I format for that condition?
Thanks
Jim
 
Back
Top