Options

NAV 2015 - word Reports layout

2»

Comments

  • Options
    chrisdfchrisdf Member Posts: 82
    Hi,

    Just to be thorough I tried your suggestion - this is what I did.

    1. Cleared my table line that was holding Sales Invoice Line data.
    2. Set the whole table to have no alignments.
    3. Dropped the usual fields back into the table but this time using the raw "Unit Price" field instead of a formatted text variable.
    4. I changed the properties on the "Unit Price" field in Table 113 to BlankZero=Yes ; AutoformatType=2 ; AutoFormatExpr = GetCurrencyCode
    5. I then dropped the repeater line across all the fields.
    6. Word immediately set a Left Alignment on all the fields (as before)
    7. On printing the Invoice, the "Unit Price" field was left aligned and showing "0.00" in comment lines on the layout.

    So really no change at all I'm afraid - I'm still on CU6 - can you advise if updating my client will do any better? Could you also advise if the "BlankZero"property is being considered when you are fudging the alignments?

    Thanks!
  • Options
    chrisdfchrisdf Member Posts: 82
    I found a new problem with the WordMergeDataItem property when writing a Word layout for the Sales Order confirmation.

    I have a test database and in it some sales orders. Most of them have a sensible number series like SO123456 and things are OK there. However, at some stage in the past the number series got reset and I have some sales orders numbered 1..99999 so (for example I have a sales order numbered "14" in my SO list).

    The Word layout for this order was repeating 3 times and driving me crazy until I removed the WordMergeDataItem property and then it printed correctly.

    To test this, I created a new sales order (SO003921) using "Copy Document" as an exact copy. This prints fine whereas the originating sales order (14) did not.

    I put a hard line of code in the report

    Document.SETRANGE("No.",'14');

    to absolutely tie the report to the number and it still fails printing 3 times (same information and the page number on each page says 1/1).

    This may not be a problem with a proper number series but there is clearly something "wrong" with this property!
  • Options
    chrisdfchrisdf Member Posts: 82
    Previous to my previous message, I found the issue.

    I had overlooked to filter the Sales Header to type "Order" - so because I have multiple sales order headers with the same number (even though different types) the behaviour of the Word reporter was to repeat the document a number of times.
  • Options
    GonzaloGonzalo Member Posts: 19
    Why Microsoft doesn't use the standard report 206 (sales invoice) with this word layout?? Maybe it doesn't work in that sort of reports, does it?
    I'm struggleing with a report similar to the 206.
  • Options
    chrisdfchrisdf Member Posts: 82
    Hi,

    I have recently loaded Office 2016and we still have the same problem with Word automatically left-justifying data in a repeater. I thought Bardur had said this was an acknowledged bug in Word?

    If Bardur is still monitoring this thread, could you possibly reply?

    It really makes the Word reporting tool very annoying to use i.e. have to right align the repeater fields before saving - "every time"!
  • Options
    barandenizbarandeniz Member Posts: 44
    edited 2015-12-29
    How are you guys getting page totals if you need to print a posted sale invoice (1306) which needs more than 1 page ? i.e a invoice contains 120 lines so it will be 3-4 page report. we need to see subtotals on the end of the every page. and TotalAmount on the last page. We can not see the subtotal if the report exceeds 1 page. Any ideas?
  • Options
    gerdhuebnergerdhuebner Member Posts: 155
    edited 2016-09-14
    Concerning alignment or other "format-lost-issues", there is a simple workaround:
    Just put a space character before or after the plain text content control. Then any special format should be preserved.
    If the paragraph (table cell) has to be right aligned, it may be necessary to insert a non-breaking leading space (Ctrl+Shift+Space).
  • Options
    chrisdfchrisdf Member Posts: 82
    Where would you put the Ctrl+Shift+Space? Directly on the word layout or as an imbedded character (from NAV) in the string that's being output to the content control within the repeater.

    I just tried this by opening an Invoice layout - the fields within the repeater are adjust back to left aligned - putting in the Ctrl+Shift+Space characters at the beginning of the content control within the repeater. I then right aligned the fields and saved the document - when I re-open it, the fields are shifted back to left aligned again :(
  • Options
    chrisdfchrisdf Member Posts: 82
    Sorry - my mistake here - I was not putting the CTRL+SHIFT+SPACE character in front of the content control (was putting it into the content control itself) works now - thanks very much for this workaround :)
  • Options
    gerdhuebnergerdhuebner Member Posts: 155
    @chrisdf
    You're welcome! Perhaps, you might be interested in a new tool, called Wordlayout+, which is a simple extension of NAV standard functionality and provides things like nested repeaters, manual line breaks within plain text controls, refined image handling and much more. You can find information and download link here: https://massivedynamicsblog.wordpress.com/2016/09/15/wordlayout/
Sign In or Register to comment.