Hi all.
I'm modifying standard invoice report (206), because I want to change the order in which the registered invoices are printed. Rather than no. I want to be sorted by bill-to name, e.g.:
Invoice no. 12 - Bill-to name A
Invoice no. 8 - Bill-to name B
Invoice no. 15 - Bill-to name B
Invoice no. 3 - Bill-to name C
Invoice no. 6 - Bill-to name D
Invoice no. 13 - Bill-to name D
.
.
.
The problem is always sorted by number. I've tried:
- Change the "Sales Invoice Header" Dataitemtable view property to "Bill-to Name". -> No success.
- Change the order property in all the tables of the layout. -> No success.
What else I can try? It is impossible?
Thanks in advance. Regards.
*This post is locked for comments
add a new key to table sales invoice header "bill-to name, no." and use the new key as new sorting key in report 206. you can to it also by code using setcurrentkey.
alternative option: copy the (filtered) records in report 206 into a temp table tempsalesinvheader one by one and resort the recs within the loop.
HiJose Angel Lopez,
Create one new key in Sales Invoice Header table, key name : Bill-to Customer No.,No.
go to 206 - Sales Invoice Header Report, Sales Invoice Header Data Item Properties, set
DataItemTableView field - SORTING(Bill-to Customer No.,No.)
Hi Miguel, I've opened your link and it´s an older version than the one I have installed. :-(
Thanks.
Hi Miguel.
Your link does not work, can you send it again?
Thanks.
I would advise you not to tamper the standard 206 report. It would be better to create a copy of it, on your object ID range and to work on that copied version. By using Report Selection functionality you can simply change the report called when printing invoice. Avoid changing the standard objects whenever possible and isolate your changes in separate objects as much as you can. If you must change the standard object, do it with as less code as possible.
Hi Jose Angel, did you solve your issue??
Hi again! I think that you can solve your issue applying a hotfix. For R2 I found that: mbs2.microsoft.com/.../KBDisplay.aspx;EN-US;2934571
But if you want to be sure, apply the latest CU :-)
Good luck and please, let me know the results!
Sorry to hear that. I've tried this in NAV2015 and it works ok there.
Hi Jose Angel,
Did you try activating "interactive sorting" feature (it allows sorting the report columns as needed).
The setup for this feature is simple. In the necessary textbox, enable the Interactive Sorting property and assign the sorting cell:
It is also possible to assign the sorting to multiple cells at the same time, so that each report column will be sorted separately.
Hope this helps!!
Sohail Ahmed
2
mmv
2
Amol Salvi
2