111
Views
7
Comments
How to filter the data of comboboxes based on other filters as excel
Question

Hi,

I am trying to filter the data of one combo box data based on the other combo box selection as excel even though they don't have any relation between them in the database. For example: If I  have three rows in table columns are PERSON NAME, AGE, SALARY and we have 3 combo boxes for them, If we select a certain amount in the salary combo box then the name and age filters should have only the data related to that particular salary. Can anyone suggest me how to do this?

Regards,

Trinusha.


Rank: #636

Hi Trinusha,

I made you a quick example you can take a look at. I created only two Combo boxes, but I hope you get the point. If you have any questions, please do comment and I'll try to help as soon as I can. 


Best regards,

Miguel Marçal

PeopleSalary.oml

mvp_badge
MVP
Rank: #148

Hi trinusha karumanchi,

You need to use the combo box property onchange (on the first combobox), to call an action and execute some logic, where that logic needs to setup the range of values you need for the second combobox.

Hope this helps!

Regards

mvp_badge
MVP
Rank: #2

Hi Trinusha,

In general, these are the steps:

  1. Set the On Change Property of the Combo Boxes that influence another to a Screen Action;
  2. In the Screen Action, do whatever you need to do to limit the data in the other Combo Boxes (e.g. Refresh Data), and Ajax Refresh the Combo Boxes.

EDIT: Damn, you guys are fast :).

mvp_badge
MVP
Rank: #2

Hi Trinusha,

The information we gave should be sufficient for you to write the right code. It's all about getting the right data from the database. If you don't know how to do that, perhaps you should revisit some of the tutorials...