Hello,
I have been trying for a while to add comments to my xslx file generated using xslx4j.
Comments.xml is getting adde to package with the right content but somehow comments are not shown in xslx.
Im using docx4j 2.8.1
Here is my code :
final WorksheetPart worksheet =
pkg.createWorksheetPart( new PartName( "/xl/worksheets/sheet1.xml" ),
"Sheet1", 1 );
final CommentsPart commentsPart = new CommentsPart();
CTComments comments = Context.getsmlObjectFactory().createCTComments();
CTCommentList commentlist = Context.getsmlObjectFactory().createCTCommentList();
commentlist.getComment().add(createComment());
comments.setCommentList(commentlist);
commentsPart.setJaxbElement( comments );
worksheet.addTargetPart( commentsPart );
Pls point me out whats going wrong here.
Thanks.