Thinking laterally, wouldn't you be better off with a combo box in place of
textbox1. You could limit the rowsource of the combo box to the permitted
entries. Then, if you put a combo box in place of textbox2, you could
programmatically restrict the rowsource of the second combo using the
AfterUpdate event of the first combo.

Guy Harley


-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of holein_one2001
Sent: Thursday, 2 February 2006 3:14 PM
To: [email protected]
Subject: [ms_access] Re: validation rule for text box

Thank you all for your help.
I may have simplified my question too much.

I really want to restrict text box input to a single letter A through
N. The text box is on a form with another text box where I want to
enter single ASCII number (or regular number whichever is better). If
the Letter entered in TextBox1 is A, then the number entered in
TextBox2 must be one of 1-13,101-108. If TextBox1=D, for example, then
TextBox2 is restricted to the numbers 1-14,101-111. A14 and D198 are
invalid. Valid numbers are dependant on the entry in TextBox1 and the
range of numbers is different for every Letter.

I eventually want to make each letter/number combination mutually
exclusive and make it an error to use the same combination again.

Maybe I should just make a table with all the possible combinations
and use it as a drop down list in a form.

The form was generated by the Access form wizard from an existing
table that has two fields, Row & Seat.

Thank you,
Mark Espinosa 



 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/ms_access/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to