× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi Vern

Thanks for your reply .. i have try to look for some example but i found
only java example and i'm not expert in java .. i tryed to understand this
java example and how to convert in RPGLE but i don't understand to menage
"factory" object

This is the link that i have found
https://stackoverflow.com/questions/7153254/how-to-add-cell-comments-to-exce
l-sheet-using-poi

public void addComment(Workbook workbook, Sheet sheet, int rowIdx, int
colIdx, String author, String commentText) {

CreationHelper factory = workbook.getCreationHelper();

//get an existing cell or create it otherwise:

Cell cell = getOrCreateCell(sheet, rowIdx, colIdx);



ClientAnchor anchor = factory.createClientAnchor();

//i found it useful to show the comment box at the bottom right
corner

anchor.setCol1(cell.getColumnIndex() + 1); //the box of the comment
starts at this given column...

anchor.setCol2(cell.getColumnIndex() + 3); //...and ends at that
given column

anchor.setRow1(rowIdx + 1); //one row below the cell...

anchor.setRow2(rowIdx + 5); //...and 4 rows high



Drawing drawing = sheet.createDrawingPatriarch();

Comment comment = drawing.createCellComment(anchor);

//set the comment text and author

comment.setString(factory.createRichTextString(commentText));

comment.setAuthor(author);



cell.setCellComment(comment);

}



Can some help me ?

Thanks in advance


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.