Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Suggested answer

Can i get Sales Order totals for specific lines x++

(0) ShareShare
ReportReport
Posted on by 46

Can i get Sales Order totals for specific lines x++

i wanna get Sales Order totals for specific lines in sales order, i know how to use Salestotal class to get all salesorder total but i wanna get lets say some lines total and other not based on my criteria

is this possible ?

  • huijij Profile Picture
    huijij 19,811 on at
    RE: Can i get Sales Order totals for specific lines x++

    I think it's possible, the calculations rules are in the calc() method in class TradeTotals and you can try to add your own criteria based on his logic.

    22655671.png

  • Suggested answer
    Bharani Preetham Peraka Profile Picture
    Bharani Preetham Pe... 3,587 Super User 2024 Season 1 on at
    RE: Can i get Sales Order totals for specific lines x++

    Yes you can count the number of loop and if it is your Id where total not required just skip that by using continue;

  • OmarAbdlhamed Profile Picture
    OmarAbdlhamed 46 on at
    RE: Can i get Sales Order totals for specific lines x++

    Hi Judy

    this action will give me all lines total

    i mean if i have line

    1

    2

    3

    4

    i need to get totals for only lines 1,2,3 i don't wanna 4 ,, is this possible using X++ ?

  • Suggested answer
    huijij Profile Picture
    huijij 19,811 on at
    RE: Can i get Sales Order totals for specific lines x++

    Hi OmarAbdlhamed,

    You can view the totals using the user interface of the system. Accounts receivable > orders >All sales orders >Click on the sales order number > Sales order tab > View group > click the ‘Totals‘ button.

    484684.png

    And you can access the D365 sales order totals information using x++ code.

    dynamics365musings.com/.../

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

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Congratulations to the January Top 10 leaders!

Check out the January community rock stars...

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,996 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,853 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans