Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Suggested answer

Filter on Report is not working

Posted on by 50

Hi All,

           I am doing a report in that I am giving the  setfilter value true for only advance invoice field, but in the report it is taking the false value of the advance  invoice field, In the report filters also I am setting the advance invoice field to true, but from that filter also it is taking the false value only, can anyone help me.

pastedimage1678371983500v1.png

pastedimage1678372046031v2.png

Thanks & Regards

  • Suggested answer
    NAV_with_Narang Profile Picture
    NAV_with_Narang 2,236 Super User 2024 Season 1 on at
    RE: Filter on Report is not working

    Instead of SETRANGE on OnPreDataItem, you can use the below Data Item property

    Illustrations/Documents:

    https://learn.microsoft.com/en-us/dynamics365/business-central/dev-itpro/developer/properties/devenv-dataitemtableview-property 

    pastedimage1678376827498v1.png

      dataitem("Purchase Header"; "Purchase Header")
        {
            DataItemTableView = SORTING("Document Type", "No.") WHERE("Document Type" = CONST("Blanket Order"));
        }

  • Sarath9999 Profile Picture
    Sarath9999 50 on at
    RE: Filter on Report is not working

    Hi Mohana,

             I tried the setrange but it is also not working, it is showing the advance invoice false values only.

    Thanks & Regards,

    Satish.

  • Suggested answer
    Mohana Yadav Profile Picture
    Mohana Yadav 59,139 Super User 2024 Season 2 on at
    RE: Filter on Report is not working

    try

    Setrange("Advance Invoice", true);

    Setfilter("Remaining Amount", '<>0');

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans