This topic is locked

Variable number of items in a lookup

5/7/2009 6:39:08 PM
PHPRunner General questions
S
shep author

I am new to PHPRunner. I can't seem to figure out how to do this with the lookup wizard. Can anybody make a suggestion?
I have an entry in a table, iMaxNumbers, that will contain a number from 1 to, in this case, 20. This entry is effectively in a 'category' table. So, while adding a record, the user will first choose a category for one field via the lookup wizard then for the next field I wanted them to be able to choose from a list of numbers that will be <= iMaxNumbers.
So, for example, suppose I have two categories:
CatOne has a iMaxNumbers set to 5

CatTwo has a iMaxNumbers set to 10
The user selects CatOne in a drop down, then I wanted the next drop down to show a choice of numbers from 1 to 5.

The user selects CatTwo in a drop down, then I wanted the next drop down to show a choice of numbers from 1 to 10.
Thanks for any tips.

J
Jane 5/8/2009

Hi,
you can create new table for this numbers with following fields: NumberField and Category.

Then set up category and iMaxNumbers as dependent dropdown boxes.