Valildation based on previous cell entry

cassowary43

New member
Local time
Today, 15:12
Joined
May 6, 2006
Messages
7
I'm new to this forum and I'm sorry if this is a repeat question...I looked in previous threads, but could not find my particular questions.

Here's the situation:
I enter a bird name in my form (I've set up a combo box of 200 choices). Each bird species has an max and min possible wing measurement. So when I enter a newly captured bird in my form, the wing measurement must fall between the minimum and maximum for that particular species. I've done similar things with cascading combo boxes, but can't figure out how to the do a between-type statement in this situation.

Thank you much,
Erik
LSU, Baton Rouge, LA
 
It is not real clear *where* you are doing the test but just use => and =< for the between test.
 
Ok, I'm not worried about those. In cascading combos that I have set up before, I go under properties, then row source and create a SQL statement Query builder. That allows to choose from a list of things based on the thing I entered in the previous cell.

But now I want this "list of things" to be the upper and lower limits of a value that I enter. These limits are in a table under two columns (max wing and min wing). How to I build an SQL query to set these limits? Or is there another way other than an SQL query?

Thanks,
Erik
 
If you are pulling the two additional fields into the previous ComboBox then you can reach those fields by using the .Column property. Forms!ComboBoxName.Column(2) would be the third column in the zero based column index.
 
I'm terribly sorry, but I'm just not getting it. I don't want to take up anyone's time if this is getting too lengthy. If it pleases you, please elaborate more on what you mean or offer another suggestion, as I'm not getting the previous suggestion to work. By the way, these upper and lower values are just that...I want the value I enter to be between these two values. If it is not, then an error message should pop up and tell me that I'm too high/low.
 
Maybe you could post your db stripped of any sensitive data but with enough sample data to demonstrate the problem and we could show you by making the changes and posting back.
 
Ok, here's a very basic file that has what I'm looking for. Basically, the table "morphometrics" has the species list and the respective max and min wing measurements. I want to enter data on birds that are newly captured. So I have set up the form "Data Entry." When I enter the wing measurement, it must fall between the max and min for that particular species. If not, it would be great to have a message come up that allows me to either confirm or reject the wing measurement entry.

Thanks so much!
Erik
 

Attachments

Users who are viewing this thread

Back
Top Bottom