I'm creating an Excel file by x++, in Dynamics 365 - D365, I would like to add the background color by X++.
I'm using this code
var package = new OfficeOpenXml.ExcelPackage(memoryStream)
var worksheets = package.get_Workbook().get_Worksheets();
var worksheet = worksheets.Add("SHEET");
var cells = worksheet.get_Cells();
var currentRow=1 ;
var cell = cells.get_Item(currentRow,1);
cell.set_Value("__MY__Value");
// NOT Work - compile error
//cell.Style.Fill.BackgroundColor.SetColor(System.Drawing.Color::FromArgb(190, 0, 0));
//cell.Style.Fill.BackgroundColor.Rgb(Winapi::rgb2int(255,255,255));
How can I use the Background color property about Excel cell, by X++ in right way?
Thanks in advance.