• If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Announcement

Collapse
No announcement yet.

Hiding a filter but the filter value still persists

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Hiding a filter but the filter value still persists

    I have a set of filters on a grid and one of those filters can be hidden, or not, as required. When the filter field is hidden it seems to still affect the filter behavior. Scenario: When the filter is displayed and the user selects a value for the filter (this is a dropdown), the filter works fine. When the filter is hidden the value that was in the filter still seems to persist even though the filter is not being displayed. I have tried doing a reset to the filter, conditioned on the same app variable that hides the filter, but this caused the app to go into a loop where the page was constantly being rendered alternately displaying the grid and filters with, and then without, the filter in question. Do I need to progammatically clear the filter when the filter is not being displayed?
    Last edited by paultherrien; 10-18-2022, 04:53 PM. Reason: fixing typos

  • #2
    Hi Paul,

    Yes for right now when you're setting the filter to hidden you need to clear it out or set it to blank. We will look at adding the logic to not apply if hidden in a future 6.1 update

    Thanks

    Comment


    • #3
      Ok, Thanks.

      Comment


      • #4
        I found that I was able to use the Set Filter app variable link for the filter in question. When I hide the filter I also set the value of the filter to " ". The only minor issue is that the page gets rendered twice in succession - once when I set the app variable to hide the filter and again when I set the app variable to set the filter field value. I execute both of these setappvar()s in the filter program, one statement right after the other. I have tried switching the order of the setappvar() statements and it doesn't appear to make a difference which is executed first. But for the most part this is now working. Thanks again.

        Comment

        Working...
        X