PerfectForms Forums » General

Filtering results displayed in a table

(4 posts)
  1. jimmyc
    Member

    Hey is there a way to "filter" the rows that are populated into a table. So say I have a search page and it contains a button that has a connection behavior that populates a perfect forms table with resutls. Lets say a user enters search text, clicks the search button and gets way more results than they wanted. Instead of making another database call and clicking the search again, is it possible to just filter the data thats already in the table. If not, from a performance standpoint this could be a useful feature.

    Posted 6 months ago #
  2. ijobling
    Member

    Look at how the SetTable Rows behaviour can help you where you can iterate through the table row by row and run actions on each row (perhaps in this case a condition that is checking a condition is satisfied and if so, you could 'delete this row')

    Posted 6 months ago #
  3. jimmyc
    Member

    What would I use to loop through the table rows?

    Posted 6 months ago #
  4. ijobling
    Member

    this is what the 'set table row' behaviour does.
    see here
    http://www.perfectforms.com/Documentation/manual/html/fl_set_table_rows.htm

    The best way to understand what you can use this form is to set up a simple test form. start with a simple process (ie run the form, enter data into the table for say 2 or 3 rows in a text field, then invoke your SetTableRow script from a button and do something simple like 'set field' as the 'action' to change the text in the row to something else and see how it iterates through the row. Do this by using the DEBUG option in the Forms area - under where also can Form | Preview.. Debug is below and you will see the script run as you invoke to help you see how it is working.

    understand the basic concept at this simple level then a lot easier to then use that knowledge in more complex scenarios

    Posted 6 months ago #

RSS feed for this topic

Reply

You must log in or register to post.