Assembly order comments not being copied during POST


I think I’ve discovered a bug in NAV 2013 … When I add some comments to an assembly order (either header comments or line comments) they get lost when I post the order (after posting, going to posted assembly order and viewing comments results in no comments to be found!).

Before you say it, YES I have enabled copying comments during posting in Assembly Setup.

I’ve looked into the issue and discovered the problem: when new comment lines are being created they are created with document type = Quote instead of Assembly order (why there is this type at all I’m not sure … ). If I create some comments, open up the assembly comment line table in dev environment and change type of those lines to assembly order, then post assembly order everything works properly. Obviously the copy comments functionality only does so if the line type is assembly order.

I was hoping though that someone would have a tip for where I could try to fix this myself?

If you can replicate it in demo database then you can report it to Microsoft here

Just replicated it in the demo database and filed a report.

Do you have any idea where I would fix this? Would it be in the code for the assembly comments lines? (I’m pretty new to NAV programming) There isn’t a lot of code in there, only really a SetupNewLine function that I believe gets called from the assembly comments worksheet page. Maybe I’ll play with that and see what I can do. I suspect it’s just defaulting to the first Document Type in the list rather than being set properly.

Thanks for the link to the NAV suggestions website - I didn’t know that existed!

Alright, I solved my problem with a bit of head scratching. The problem ended up being that the Document Type field in Assembly Comment Lines table (Table 906) didn’t have the same options as the Document Type field in the Assembly Header table (table 900). So when creating a new comment line, it was trying to filter the assembly comment lines by Document Type = “Order” (the doc type for the assembly header) whereas the comment line type was “Assembly Order”. This resulted in the Document Type filter to be blank which then defaults to the first option (quote).

To fix this, just open up Table 906 (Assembly Comment Line) in design mode, go to properties for the Document Type field, and in the OptionString property, rename “Assembly Order” to “Order”. Then you can do the same for the OptionCaption property if you want. Voila, that’s all there is to it.

Thank you for sharing the solution :slight_smile:

No problem! If it helps someone else solve the same problem in the future then it’s worth the few minutes of my time posting the solution.