Back to Devexpress

ThreadedCommentAuthor Interface

officefileapi-devexpress-dot-spreadsheet-acfda809.md

latest2.9 KB
Original Source

ThreadedCommentAuthor Interface

Contains information about the author of the comment.

Namespace : DevExpress.Spreadsheet

Assembly : DevExpress.Spreadsheet.v25.2.Core.dll

NuGet Package : DevExpress.Spreadsheet.Core

Declaration

csharp
public interface ThreadedCommentAuthor
vb
Public Interface ThreadedCommentAuthor

The following members return ThreadedCommentAuthor objects:

Remarks

Use the ThreadedCommentAuthor class instance to manage a provider ID and user ID of a comment author. You can pass the object as a ThreadedCommentCollection.Add or ThreadedComment.Reply method parameter to create a comment or reply from the specified author.

Example

The code sample below creates a new object, specifies the provider and user identifiers, and uses this object to create a comment:

csharp
var workbook = new Workbook();
workbook.LoadDocument(@"C:\Docs\Comments.xlsx");
Worksheet worksheet = workbook.Worksheets[0];
var comments = worksheet.ThreadedComments;

var author =
  worksheet.CreateThreadedCommentAuthor("Ryan Anita W", "S::[email protected]::ccdb79f7-8acb-46ab-a6d9-4f4340797155", "AD");

comments.Add(worksheet["D5"], author, "Thank you");
workbook.SaveDocument(@"C:\Docs\Comments_upd.xlsx");
vb
Option Infer On

Dim workbook As New Workbook()
workbook.LoadDocument("C:\Docs\Comments.xlsx")
Dim worksheet As Worksheet = workbook.Worksheets(0)
Dim comments = worksheet.ThreadedComments

Dim author = worksheet.CreateThreadedCommentAuthor("Ryan Anita W", "S::[email protected]::ccdb79f7-8acb-46ab-a6d9-4f4340797155", "AD")

comments.Add(worksheet("D5"), author, "Thank you")
workbook.SaveDocument("C:\Docs\Comments_upd.xlsx")

See Also

ThreadedCommentAuthor Members

DevExpress.Spreadsheet Namespace