setCellComment - cfsimplicity/spreadsheet-cfml GitHub Wiki
Sets the comment properties of a cell.
setCellComment( workbook, comment, row, column )
Required arguments
workbook
spreadsheet objectcomment
structrow
numericcolumn
numeric
Chainable? Yes.
The comment struct may contain the following keys:
anchor
author
bold
color
comment
font
italic
size
strikeout
underline
visible
The following keys are currently only supported with XLS (binary) workbooks - they will have no effect on XLSX workbooks:
fillcolor
horizontalalignment
linestyle
linestylecolor
verticalalignment
Refer to the ColdFusion SpreadsheetSetCellComment docs for details
Example
spreadsheet = New spreadsheet();
workbook = spreadsheet.new();
spreadsheet.addColumn( workbook, "a" );
theComment = {
author="cfsimplicity"
,comment="This is the comment in row 1 column 1"
,bold="true"
,color="blue"
};
spreadsheet.setCellComment( workbook, theComment, 1, 1 );