// Create a new workbook Workbook workbook = new Workbook(); IWorksheet worksheet = workbook.getWorksheets().get(0); //create comment for range C3. IComment comment = worksheet.getRange("C3").addComment("Range C3's comment."); //change comment's text. comment.setText("Range C3's new comment"); // Save to an excel file workbook.save("AddComment.xlsx");