Selecting Records for a List-Type form

I could kick myself for not knowing how to do this, but I don’t! I have a simple list form, using 1 table. I filter some records in the SourceTableView property of the form. [?]In the OnAfterGetRecord, I want to do some more complex processing, to decide if I want to display the record or not. Can I decide not to display the record from this trigger? If so, how? Thanks, Andy

Hi Just an idea: Add a field ‘Show’ to your record. Run at first (in a codeunit): YourRec.FIND('-'); REPEAT IF YourRec.YourField <> YourOption THEN YourRec.Show = False ELSE YourRec.Show = True; YourRec.Modify; UNTIL YourRec.NEXT =0; Then run your form with the following settings: SourceTableView: SORTING(Show) ORDER(Ascending) WHERE(Show=FILTER(True)) Then the user isn’t able to delete the filter [;)]. All other filters should work also here. YourForm.Run; bye André

Hi Andy, Or try putting something like this in the onopenform trigger: FIND(’-’); REPEAT IF rec.field=condition THEN MARK(TRUE); UNTIL Rec.NEXT=0; MARKEDONLY(TRUE); I guess it all depends on how important it is that the user cannot then “unhide” the records. Regards, Jon

[:)]Many thanks for the ideas. One of those 2 ideas will certainly work. Ta, Andy