web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Suggested Answer

Need to show data From posted Purchase Invoice based upon Posted Purchase receipt

(0) ShareShare
ReportReport
Posted on by 5

Hi,

I'm Creating Report where I'm fetching data from Posted Purchase Invoice based upon the order number between Receipt & Invoice.

But for Same order No. It only picking first value and  displaying in report

 PurchInvHead.SETRANGE("Order No.", "Order No.");
                IF PurchInvHead.FindSet() THEN begin
                    repeat
                        BillNo := PurchInvHead."Vendor Invoice No.";
                        PurchInvHead.CalcFields("Amount Including VAT");
                        Amt := PurchInvHead."Amount Including VAT";
                        Num := PurchInvHead."Order No.";
                    until PurchInvHead.Next() = 0;
                end;
Var
 PurchInvHead: Record "Purch. Inv. Header";
This is my code.
  • Suggested answer
    Suresh Kulla Profile Picture
    50,280 Super User 2026 Season 1 on at

    Because you are replacing the billno and other variables every time you are in loop, so it will show only the last invoice values. You need use the Purchase Invoice Header as dataitem and then use the columns Vendor Invoice No., amount and so on.. and then in the report when you use those columns it will display correct values.

  • Suggested answer
    riya patel Profile Picture
    82 on at

    It can Happen Maybe because you Have Not selected the Detailed row in RDLC

    If my answer was helpful please verify it by clicking Yes

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 624 Super User 2026 Season 2

#2
YUN ZHU Profile Picture

YUN ZHU 440 Super User 2026 Season 2

#3
Teagen Boll Profile Picture

Teagen Boll 244 Super User 2026 Season 2

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans