I am trying to change the column names when the Aged AR report is exported to excel in Dynamic NAV 5.1.
For example, when the data is exported to excel, I want the column heaading for PO number to be 'PO Number' instead of 'External Document No'
The code used to show this column is ExcelBuf.AddColumn("Cust. Ledger Entry".FIELDCAPTION("External Document No."),FALSE,'',TRUE,FALSE,TRUE,'');
Can anyone please help me with some suggestions?
0
Comments
Then why not replace
"Cust. Ledger Entry".FIELDCAPTION("External Document No.")
to
ExcelBuf.AddColumn('PO Number'),FALSE,'',TRUE,FALSE,TRUE,'');
:-k
is this code in the report?
http://www.BiloBeauty.com
http://www.autismspeaks.org
I tried changing that but I am getting an error message asking to initialize the variable.
'You have specified an Unknown Variable. PO Number. Define the variable under Global C/AL Symbols'
ExcelBuf.AddColumn('PO Number'),FALSE,'',TRUE,FALSE,TRUE,'');
should be
ExcelBuf.AddColumn('PO Number',FALSE,'',TRUE,FALSE,TRUE,'');
remove the extra left paren
It worked! I was able to rename a number of columns!