ColdFusion 2021 SpreadsheetFormatCell colors

Viewed 304

Recently upgraded to CF2021 from CF11. I have a spreadsheet that we format cells, rows, and columns with colors, particularly background colors. I specify either color= or fgcolor=. No matter what color I choose, it will be black. I've searched and searched but find nothing for 2021.

Anybody have a solution?

Very simplified code. It works in CF11 and CF2016.

<cfscript>
    sObj = SpreadsheetNew("Testing Summary","yes");
    SpreadsheetSetCellValue(sObj,"As of: " & DateFormat(#DateAdd("h", -1, Now())#),1,1); 
    SpreadsheetFormatCell(sObj, {bold="true", fontsize="14"}, 1,1);
    SpreadsheetMergeCells(sObj,1,1,1,5);
    SpreadsheetSetCellValue(sObj,"Testing Summary",2,1); 
    SpreadsheetMergeCells(sObj,2,2,1,5);
    SpreadsheetFormatCell(sObj, {bold="true", fontsize="20", fgcolor="blue", color="yellow"}, 2,1);
</cfscript>

<!--- Launch File to User --->

<cfheader name="Content-Disposition" value="attachment; filename=MySpreadsheet.xlsx"> 
<cfcontent type="application/vnd.ms-excel" variable="#SpreadsheetReadBinary( sObj )#"> 
0 Answers
Related