Report Rendering - BC v21 - Selecting specific layout through an action

garmoogarmoo Member Posts: 12
Hi all, I have just learnt about the new rendering section in reports today. I'm not finding much information about it online, and was wondering the following:

If I have a Sales Shipment report extension set up using Rendering as below
rendering
    {
        layout(SalesShipment)
        {
            Type = RDLC;
            LayoutFile = './src/reportextension/layouts/50100.SalesShipmentExt.rdlc';
        }
        layout(CommercialInvoice)
        {
            Type = RDLC;
            LayoutFile = './src/reportextension/layouts/50101.CommercialInvoice.rdlc';
        }
    }

is it possible to call this report from an Action and specify that I want it to display using the Commercial invoice RDLC?
trigger OnAction()
                var
                    SalesShptHeader: Record "Sales Shipment Header";
                    SalesShipment: Report "Sales - Shipment";
                begin
                    SalesShptHeader := Rec;
                    SalesShipment.SetTableView(SalesShptHeader);
                            <--- set rdlc required here
                    SalesShipment.Run();
                end;
Sign In or Register to comment.