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

Community site session details

Session Id :
Supply chain | Supply Chain Management, Commerce
Suggested answer

PowerApps : Fetch Number sequence from D365 F&O to PowerApps

(1) ShareShare
ReportReport
Posted on by 40

Hi Experts,

I am creating an App which will create new sales order in Dynamics 365FO, and so far with help of community and forums I am progressing well on it. (Still new to the world of PowerApps and Flow).

Automatic number sequence is setup in D365 for the SalesOrders entity and I need to tell the app to use it when generating new number, but I am currently stuck on it.

Let me describe the whole scenario, maybe you can point out something i did wrong.

 

The App is really simple as concept. It containts 2 Edit Froms in which I have used the Dynamics 365 Fin Ops connector in order to get the 2 tables which i need "SalesOrderHeadersV2" and "SalesOrderLines".

I have selected few fields which I need for the end user to fill in.
Here is how it looks:

6204.pastedimage1594019265280v1.png

And for the functions I have done the follwoing:
Set the button's OnSelect Property to SubmitForm(F_SalesHeaderV2)
OnSuccess property of that form is set to SubmitForm(F_SalesLines)

 

OnSuccess property of sales lines will reset both forms to allow next SO and Line to be created. So I set it to ResetForm(F_SalesHeaderV2); ResetForm(F_SalesLines)

8105.pastedimage1594019265281v2.png

I am not looking for manual generate of SO number, I want the data field from the app to communicate with the number sequence(how it is usually the standard process in Dynamics) and automatically generate new number when the sales order is being submitted/created from the App.
Unfortunately I cannot accomplish this now and it is real struggle for me. Maybe there is something that I am doing wrong.

For the same thing I was suggested to Default the value of SalesOrder with the following formula : F_SalesHeaderV2.Lastsubmit.SalesOrderNumber - which dosen't work, and the second suggestion was to add +1 to it, which I am not sure how is done.

As well I cannot ignore the filed in the App, as it is one of the 2 mandatory fields one you add the table , so I can only hide it , but it still needs to function within the app.

Any suggestions will be Highly appreciated.

I have the same question (0)
  • Suggested answer
    Ludwig Reinhard Profile Picture
    Microsoft Employee on at
    RE: PowerApps : Fetch Number sequence from D365 F&O to PowerApps

    Hi,

    Defining the sales order number from the App will probably not work because you cannot access the number sequences from your PowerApp.

    I am also not sure if this is a viable approach to use an App for that and uploading the information via the data entities.

    Why?

    Example:

    How many items do you have and do you want to use/lookup from D365FO?

    If you have more than 2000 you will run into delegation issues.

    The same applies for your vendors, warehouses and alike.

    Can't you use the data management workspace to upload your sales orders?

    That will avoid those problems and also be faster than this App.

    Best regards,

    Ludwig

  • André Arnaud de Calavon Profile Picture
    299,576 Super User 2025 Season 2 on at
    RE: PowerApps : Fetch Number sequence from D365 F&O to PowerApps

    Moved to the Dynamics 365 Supply Chain Management forum.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > Supply chain | Supply Chain Management, Commerce

#1
CA Neeraj Kumar Profile Picture

CA Neeraj Kumar 413

#2
Sagar Suman Profile Picture

Sagar Suman 198 Super User 2025 Season 2

#3
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 187 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans