Announcements
No record found.
Hello Experts,
We have created customized Customer Statement report in Business central for our Customers. Customer wanted to run that report using "External doc no". Is there any way we can do it?
Any help will be highly appreciated.
Thanks.
That field is on the customer ledger entry but the report mostly uses the detailed customer ledger entry. Using report 1516 as an example from line 515 the OnAfterGetRecord trigger is set for the "Cust. Ledger Entry" table. You'll notice at that point a number of filters are set from the request page such as the date. I would slot it in around there.
Thanks for your reply but i couldn't find any report-1516.
Which report did you base your custom one on? Report 116 is the other in the GB version at least. For report 116, try from line 544 where the same trigger I mentioned previously is stated and you have similar filters.
Yes i have taken from report 116. But we don't have External Doc no field in Detailed customer ledger entry table.
Neglected to state the code line of 544 changes the data item to be "Cust. Ledger Entry". Which does in fact have the "External Document No." field. What you'll notice about the area of code I've circled in red is that the filters from the request page are stored as variables. So in your case you can create a variable to show on the request page and then pass it into a filter in that block I've circled.
I tried as you suggested above but it didn't work. Not able to run the report using "External Doc no".
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.
Congratulations to our community stars!
Expanding mentorship, skilling, and AI innovation
These are the community rock stars!
Stay up to date on forum activity by subscribing.
OussamaSabbouh 741 Super User 2026 Season 2
YUN ZHU 514 Super User 2026 Season 2
AndrewThomas81 336 Super User 2026 Season 2