Please take a look at the General Ledger topic: Reporting Functions which reads:
The @OfficeLink() function is used to assist in formatting financial statements when exported to Excel. Without using the @OfficeLink() function the contents of financial statements are exported to Excel in a single column. This makes financial statements exported to Excel difficult to work with.
The syntax of the @OfficeLink() function is:
The first parameter or value of the function should begin with either an 'L' or 'R' code followed by the width of the Excel column, to designate the justification. If not specified, 'L' (left-justification) is assumed. Up to an additional 24 columns may be specified, by separating additional parameters with a comma. The following instruction formats the output of the financial statement into two Excel columns. The first is 40 characters wide and left justified. The second is 30 characters wide and right justified:
A financial statement exported to Excel may have a maximum of 25 columns. The @OfficeLink() function should be placed in the body section of the report and may appear in more than once place within the report, if you need to vary the formatting of the data within the financial statement, in order to produce a consistent result for Excel.
If no parameters are specified, all data is placed in the first column of the spreadsheet.
While the @OfficeLink() function can be included in a report multiple times, you may only define the left or right justification of a column once. Once a column has been defined as left justified, for example, it will always be formatted as left justified, even if subsequent @OfficeLink() commands specify right justification.
You cannot specify a column width wider than 999 characters and less than 6 characters in width. Regardless of the width of the column you specify, a spreadsheet column will be no larger than the largest data element found in any column of the spreadsheet.
If you have upgraded from an older version of CAPITAL and have also made modifications to your standard financial reports, you will need to add the @OfficeLink() function to them. Output formatting in Excel will not automatically be correct.
If you have not modified your standard financial statements it may be quicker for you to replace your old reports with the current standard financial reports, found in your \CAPITAL\MFC folder. Financial statements have the file extension *.GPT. Please sure to back-up your old reports in case you intend to replace them with the newer version as a precaution.