Filter a relation result

Hi everybody,

I have a text field which has, as dataprovider, a relation where I get the company name from: table_catalog_to_table_companies.field_name
When editing it provides a drop down list with all the company names recorded in the database.
But I would like to filter this list to get only the ones which are active: field_active = 1

How can I do that?

Cheers.

Hi,

we use a foundsetfilter for that.
The advantage is that you can use the same form for handling active and nonactive (flag is 1 or flag =0 ) items using a different Fsf,

Regards,

Hans Nieuwenhuis

Thx

But I have found another way: I use a global variable, set to the value I need, in the ‘From’ field.
I don’t know if it’s the best way to do it but it works :D

Yes, but using a foundsetfilter has the advantage of less coding.

Once the filter is active, find/search and showall, etc all work as aspected without extra coding.

Regards,

Hans