You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by Sohel Khan <kh...@gmail.com> on 2008/06/13 18:57:18 UTC

Problem while creating cell comments

Dear,

I have a blank excel sheet having some macro and command button
embadded in that. I have written a program using HSSF API to fill some
data in this sheet and create cell comment.

Now the problem is when execute this program the command button
getting removed from the excel sheet.

Please find the code i am using :

HSSFPatriarch patr = sheet.createDrawingPatriarch();//This method is
responsible for removing command button

HSSFComment comment1 = patr.createComment(new HSSFClientAnchor(2, 2,
2, 2, (short)4, 2, (short) 6, 5));
       comment1.setString(new HSSFRichTextString("We can set comments in POI"));
                               comment1.setAuthor("Apache Software Foundation");
                               comment1.setRow(2);

                               comment1.setColumn((short)2);


Please help me if you have any solutions or is there any way i can
create a command button and assign a macro fucntion to it, in excel
sheet using java program.

Thanks,
Sohel

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org