Stylesheet - sales header and sales line - calculation total

thomaschrthomaschr Member Posts: 3
I am creatinng a order document - using sales header and sales lines.
The amount appears for each line:
1 - 12
2 - 24

How ever how do I calculate the total:
Total = 36

Comments

  • NagiNagi Member Posts: 151
    Either use CALCFIELDS on fields Amount and Amount Including VAT in Sales Header or loop through the records in Sales Line an add the field Line Amount to a decimal variable.
  • thomaschrthomaschr Member Posts: 3
    hi again,
    Sorry i needed to be more specific.

    I use the Nav stylesheet tool.
    I select "sales order header" and "sales order"
    Makes both tables ( fields) available in MS Word using the mail merge.
    First I select all the fields from the sales order header - no worries.
    Then I select all the fields from the lines - no worries.

    The problem starts when I need to do the TOTAL amount of the sales order - as I ( inside Word) need to calculate the Sum for all the lines.

    Is that possible - how?
  • SavatageSavatage Member Posts: 7,142
    If the order is released then the sales header Amount field should be filled

    else,

    In word, if it creates a table you click
    Table->Formula (create your formula) like
    1
    2
    3
    4
    =SUM(ABOVE)
    10

    Sorry ( i don't have stylesheets ) but this is the methods I use.
  • kinekine Member Posts: 12,562
    thomaschr wrote:
    hi again,
    Sorry i needed to be more specific.

    I use the Nav stylesheet tool.
    I select "sales order header" and "sales order"
    Makes both tables ( fields) available in MS Word using the mail merge.
    First I select all the fields from the sales order header - no worries.
    Then I select all the fields from the lines - no worries.

    The problem starts when I need to do the TOTAL amount of the sales order - as I ( inside Word) need to calculate the Sum for all the lines.

    Is that possible - how?

    Easiest way is to have flowfield on header which will calc the sum from the lines and than you need nothing more... ;-) if the field is not there, you can add it easily...
    Kamil Sacek
    MVP - Dynamics NAV
    My BLOG
    NAVERTICA a.s.
  • ajhvdbajhvdb Member Posts: 672
    With the updated style sheet fob you can use some totals and other calculated fields.
Sign In or Register to comment.