'''' This code is part of Document Solutions for Word demos.'' Copyright (c) MESCIUS inc. All rights reserved.''ImportsSystem.Collections.GenericImportsSystem.DrawingImportsSystem.LinqImportsGrapeCity.Documents.WordImportsGrapeCity.Documents.Word.Layout '' This sample Is identical to Comments. The only difference Is'' that in PDF export, comments are ignored. This Is achieved by'' providing a GetPdfConversionOptions method used by the sample'' browser's infrastructure when it calls the SaveAsPdf method'' on the generated document.PublicClassCommentsNoPdfFunctionCreateDocx() AsGcWordDocumentDim user1 = "Jaime Smith"'' user name For comments' authorDim user2 = "Jane Donahue"'' user name For comments' author Dim doc = NewGcWordDocument() Dim pars = doc.Body.Paragraphs Dim p1 = pars.Add("Paragraph 1: This is a paragraph of text with a comment added to the whole paragraph. ")Dim c1 = p1.GetRange().Comments.Add("Comment added to paragraph 1.", user1, Util.TimeNow(), "J.S.")Dim c2 = c1.Reply("Reply to comment 1.", user2)Dim c3 = c2.Reply("Reply to comment 2, closing the thread.", user1) c3.Done = True Dim p2 = pars.Add("Paragraph 2: This is another paragraph of text, with a comment added to 3rd run. ") p2.GetRange().Runs.Add("This is run 2 of paragraph 2. ")Dim r = p2.GetRange().Runs.Add("This is run 3 of paragraph 2 with a comment. ") r.GetRange().Comments.Insert("Comment on run 3 of paragraph 2", user2, RangeLocation.Whole) p2.GetRange().Runs.Add("This is run 4 of paragraph 2. ") p2.GetRange().Runs.Add("This is run 5 of paragraph 2. ") p2.GetRange().Runs.Add("This is run 6 of paragraph 2. ") '' DoneReturn docEndFunction '' Optional static method. If it Is defined on a sample class,'' these options are used when saving the document to PDF.SharedFunctionGetWordLayoutSettings() AsWordLayoutSettingsReturnNewWordLayoutSettings() With { .CommentMode = WordCommentMode.None }EndFunctionEndClass