` Printed Icetips Article

Icetips Article



Par2: Filtering a browse at runtime
1998-04-18 -- Russ Eggen
 
There is no best way to do this.  Depending on design, depends on which embeds to 
use.  For example, I designed an app that needed to ShowAll products on file or show 
just products that are on the shelves.  I made a checkbox called ShowAll.  On the  
Control Event Handling, Accepted for this control I used this code:

!!Dynamicly change the filter for the browse
IF ShowAll                                                   !If checkbox is checked
  ProductList.SetFilter('')                               !Remove the filter and show all
records
ELSE                                                           !ELSE not checked
  ProductList.SetFilter('(PRO:OnHand > 0)')  !Filter the list
END                                                             !END
IF ShowAll
ThisWindow.Reset(1)                                   !Force refresh of the display



Printed May 6, 2024, 8:20 pm
This article has been viewed/printed 35108 times.