Comment Class |
Namespace: Aspose.Cells
The Comment type exposes the following members.
Name | Description | |
---|---|---|
![]() ![]() | Author |
Gets and sets Name of the original comment author
|
![]() ![]() | AutoSize |
Indicates if size of comment is adjusted automatically according to its content.
|
![]() ![]() | Column |
Gets the column index of the comment.
|
![]() ![]() | CommentShape |
Get a Shape object that represents the shape attached to the specified comment.
|
![]() ![]() | Font |
Gets the font of comment.
|
![]() ![]() | Height |
Represents the Height of the comment, in unit of pixels.
|
![]() ![]() | HeightCM |
Represents the height of the comment, in unit of centimeters.
|
![]() ![]() | HeightInch |
Represents the height of the comment, in unit of inches.
|
![]() ![]() | HtmlNote |
Gets and sets the html string which contains data and some formats in this comment.
|
![]() ![]() | IsThreadedComment |
Indicates whether this comment is a threaded comment.
|
![]() ![]() | IsVisible |
Represents if the comment is visible or not.
|
![]() ![]() | Note |
Represents the content of comment.
|
![]() ![]() | Row |
Gets the row index of the comment.
|
![]() ![]() | TextHorizontalAlignment |
Gets and sets the text horizontal alignment type of the comment.
|
![]() ![]() | TextOrientationType |
Gets and sets the text orientation type of the comment.
|
![]() ![]() | TextVerticalAlignment |
Gets and sets the text vertical alignment type of the comment.
|
![]() ![]() | ThreadedComments |
Gets the list of threaded comments;
|
![]() ![]() | Width |
Represents the width of the comment, in unit of pixels.
|
![]() ![]() | WidthCM |
Represents the width of the comment, in unit of centimeters.
|
![]() ![]() | WidthInch |
Represents the width of the comment, in unit of inches.
|
Name | Description | |
---|---|---|
![]() ![]() | Characters |
Returns a Characters object that represents a range of characters within the comment text.
|
![]() | Equals | (Inherited from Object.) |
![]() | Finalize | (Inherited from Object.) |
![]() | FormatCharacters |
Format some characters with the font setting.
|
![]() ![]() | GetCharacters |
Returns all Characters objects
that represents a range of characters within the comment text.
|
![]() | GetHashCode | (Inherited from Object.) |
![]() | GetType | (Inherited from Object.) |
![]() | MemberwiseClone | (Inherited from Object.) |
![]() | ToString | (Inherited from Object.) |
[C#] Workbook workbook = new Workbook(); CommentCollection comments = workbook.Worksheets[0].Comments; //Add comment to cell A1 int commentIndex1 = comments.Add(0, 0); Comment comment1 = comments[commentIndex1]; comment1.Note = "First note."; comment1.Font.Name = "Times New Roman"; //Add comment to cell B2 comments.Add("B2"); Comment comment2 = comments["B2"]; comment2.Note = "Second note."; //do your business //Save the excel file. workbook.Save("exmaple.xlsx"); [Visual Basic] Dim workbook as Workbook = new Workbook() Dim comments as CommentCollection = workbook.Worksheets(0).Comments 'Add comment to cell A1 Dim commentIndex1 as Integer = comments.Add(0, 0) Dim comment1 as Comment = comments(commentIndex1) comment1.Note = "First note." comment1.Font.Name = "Times New Roman" 'Add comment to cell B2 comments.Add("B2") Dim comment2 As Comment = comments("B2") comment2.Note = "Second note."