Add PowerBI report factbox to Page 6306 and Page 6505
We would like to add Page 6306 Power BI report factbox to page 6505 Lot No Information Card and to Page Lot No Information List. For this, functions InitFactBox() and SetCurrentListSelection() on Page 6306 have to be accessible from AL, to be able to use a pageextension. Or can these factboxes be added to both pages in the BC standard solution? Also, looking at different examples like for instance at Page 31 Item List and Page 9305 Sales Order List where PowerBI Report factbox is added, only a single field is passed through parameter CurrentSelection : Text on function SetCurrentListSelection() in Page 6306. My assumption is that multiple fields can be passed to make each line unique. If that's the case, what syntax should I use to add multiple fields? e.g. using function GetPosition()
Answer from Djordje : As for filtering on multi-field keys in Power BI reports, Business Central doesn't support it. We only support filtering on single-field keys. Also, the Power BI REST API only supports report filtering by single field keys. Please log a github issue to make functions InitFactBox and SetCurrentListSelection external.
the best solution would be to make functions InitFactBox and SetCurrentListSelection external so we can access them from AL. this way we can make a page extension and via these functions, we can initialize and show the factbox for the selected record