Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Unanswered

Dataitem in report extensions

(1) ShareShare
ReportReport
Posted on by 20
Hi all,

I have created a report extension, to get data from another table. In this report extension I have added the dataitem Sales Comment Line and this is linked to the Sales Header. 
Thereafter, I have downloaded the standard RDLC report and copied it in my extension and updated the dataset in the report. The Comment column is available. 
However, somehow I do not get the information from the sales comment line. Has someone an idea why it is not working? 
reportextension 60134 pickinstructieSchut extends /Pick Instruction/
{
    RDLCLayout = 'layouts/pickinstructieSchut.rdl';
 
    dataset
    {
        add(/Sales Header/)
        {
            column(ExternalDocumentNo; /External Document No./)
            {
                IncludeCaption = true;
            }
            column(Shipment_Method_Code; /Shipment Method Code/)
            {
                IncludeCaption = true;
            }
        }
        addlast(/Sales Header/)
        {
            dataitem(/Sales Comment Line/; /Sales Comment Line/)
            {
                DataItemLink = /No./ = field(/No./);
                DataItemTableView = sorting(/Document Type/, /No./, /Document Line No./, /Line No./) where(/Document Type/ = const(Order));
                column(Comment; Comment)
                {
                    IncludeCaption = true;
                }
 
            }
        }
        add(/Sales Line/)
        {
            column(Description2; /Description 2/)
            {
                IncludeCaption = true;
            }
            column(Item_Reference_No_; /Item Reference No./)
            {
                IncludeCaption = true;
            }
        }
        addlast(/Sales Line/)
        {
            dataitem(Item; Item)
            {
                DataItemLink = /No./ = field(/No./);
                DataItemTableView = sorting(/No./);
                column(Base_Unit_of_Measure; /Base Unit of Measure/)
                {
                }
            }
        }
    }
}
  • Suggested answer
    Kamal Khakhkhar Profile Picture
    Kamal Khakhkhar 303 on at
    Dataitem in report extensions
    Hii There,
    As per your question you need to create report extension along with that you need to download the Report , Add your fields in report as per requirement and replace it with old layout.
    here i attach a blog, video for reference.
     
     
    If you found useful mark it answered.
     
    Thank You.
    Kamal Khakhkhar

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 Verified Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,503 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans