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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / PowerApp Business Cent...
Power Apps
Unanswered

PowerApp Business Central -Header/Lines How to Document ID?

(0) ShareShare
ReportReport
Posted on by 3

I’m building a Business central (MS BC16) app with the standard on-prem connector. While trying for example a salesOrder - salesOrderLines page, I get the instruction to enter the DocumentID. In the Tables I don’t find this ID.

Which ID I do have to add in and how is the syntax?

 

Thank You!

Screenshot 2020-11-27 101227a.jpg

Categories:
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @Lanze ,

     

    In your data table, you can set filter for the items:

    Filter(salesOrderLines,SONumber=Header.SOnumber)

    "SONumber" is the column name in your salesOrderLines for the SO number, and Header.SOnumber is just an example, you probably need to figure out what is the item source, it might be a selected item from a gallery, then the code should be "Gallery.Selected.SONumber".

  • Lanze Profile Picture
    3 on at

    TY for your answer @Anonymous!
    I’m writing so late because I try your recommendation since u wrote.^^

    The usual connection fields are SOL.“Document Type”  = SO.“Document Type” AND SOL.”Document No.” = SO.”No.”. Most of them doesn’t exist in the field list for the table in the conector...

    The ; is there instead of a comma because it is a German environment.

    I tried around and current I have found this:

    I don’t know even if those are the right fields, but it seems good so far.

     

    Screenshot 2020-11-27 130335.jpg

    So far I see this come because Business Central can’t use the delegation and the usual workaround is to load the data to a collection, but here we have the same problem that we have to define documentId…

     

    Screenshot 2020-11-27 130248.jpg

    For this I don’t find a workaround, even the problem seems basic. Getting data from header/lines tables which are provided by a connector which doesn’t support delegation.

    Do you or another reader know what is to do next?

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @Lanze ,

     

    For collection, you can collect all the sale order items, for example, you can use the following formula in the property "OnVisible" of your screen:

    ClearCollect(SOItems,salesOrderLines)

    And then you can use your collection in the formula of "Filter":

    Filter(SOItems,documentID=Gallery6.Selected.ID)

    Please be noted that the formula is case sensitive...

     

  • DB-25020741-0 Profile Picture
    2 on at

    Hi,

     

    Did you ever get this working? I'm trying to achieve the same thing, but am not getting anywhere and there isn't much help available.

     

  • vierglezmtin Profile Picture
    2 on at

    HEEEEEEEEEEEELP

  • preeteebeefeya Profile Picture
    4 on at

    Got the same issue

    Any update

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!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 220 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 189 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 139

Last 30 days Overall leaderboard