Limiting Subform View

poppinspoppins Member Posts: 647
Hi everyone,

I want to limit a subform view so that it only displays the customers whose No. is equal or greater than a certain value....

How can I do that???

Comments

  • krikikriki Member, Moderator Posts: 9,112
    If you have a fixed value, you can put it in the filters.


    But I suppose it is a value given by the main form.
    So in the subform, you need to create a function that receives that value:
    Function InputParameters(TheValue)
    BEGIN
      SETFIELD("Some Field",'%1..',TheValue);
      CurrForm.UPDATE(FALSE);
    END;
    

    You also need to give a name to your subform in the main form.
    And in the main form, you need to call the function. Generally done from the OnAfterGetCurrRecord-trigger (and NOT OnAfterGetRecord!)
    CurrForm.SubForm.FORM.InputParameters('Some Value');
    
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


Sign In or Register to comment.