NAV 2016 - Export To Excel Color Line

Hi Folks -

I have a simple report that exports 5 fields to excel. User has requested that if the CreditAmt is not 0 then show the line in Red color like example shown below.  Is there any property in below code to set the entire line to Red. 

ExcelBuf.AddColumn("Customer No.",FALSE,'',FALSE,FALSE,FALSE,'',ExcelBuf."Cell Type"::Text);
ExcelBuf.AddColumn(Name,FALSE,'',FALSE,FALSE,FALSE,'',ExcelBuf."Cell Type"::Text);
ExcelBuf.AddColumn("Document No.",FALSE,'',FALSE,FALSE,FALSE,'',ExcelBuf."Cell Type"::Text);
ExcelBuf.AddColumn(DebitAmt,FALSE,'',FALSE,FALSE,FALSE,'',ExcelBuf."Cell Type"::Number);
ExcelBuf.AddColumn(CreditAmt,FALSE,'',FALSE,FALSE,FALSE,'',ExcelBuf."Cell Type"::Text);

Example

Customer No.  Name  Document No.  Debit Amt  Credit Amt

001                 ABC    123                 100

002                 DEF     456                                   50

 

Any help is highly appreciated.

 

Thanks

Related