Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #5  
Old 10-25-2023, 01:14 AM
DuchessNora DuchessNora is offline Exporting comments from word to excel - Comment.Parent property issue Windows 11 Exporting comments from word to excel - Comment.Parent property issue Office 2021
Novice
Exporting comments from word to excel - Comment.Parent property issue
 
Join Date: Oct 2023
Posts: 6
DuchessNora is on a distinguished road
Default

Quote:
Originally Posted by Guessed View Post
I think your logic is flawed. Having no replies doesn't mean the comment is a child-level comment. Instead you should be looking for presence of an Ancestor - top level comments don't have an ancestor. Then you can loop through any replies if they exist. Here is a snippet of code I'm currently using...
Code:
      For Each aCmt In wdDoc.Comments
        If aCmt.Ancestor Is Nothing Then        'a top level comment
           'do something
          If aCmt.Replies.Count > 0 Then
            For i = 1 To aCmt.Replies.Count
              Set aReply = aCmt.Replies(i)
              'do something with the replies
            Next i
          End If
        End If
      Next aCmt
I think the other code provided works for now, but if I use this one, where in the code do I need to place it? thank you
Reply With Quote
 

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Parent/Child Comment Extract amschaefer Word VBA 1 10-19-2023 11:41 PM
Exporting comments from word to excel - Comment.Parent property issue [Reviving solved thread for additional help] Exporting Tracked Changes and Comments to Excel mjungli Word VBA 4 01-11-2023 09:39 AM
Exporting comments from word to excel - Comment.Parent property issue Exporting Tracked Changes and Comments to Excel alzasp Word VBA 10 06-14-2022 02:13 AM
How to hide comments and comment indicators from OTHERS Elena A Excel 0 12-03-2014 12:08 PM
Exporting comments from word to excel - Comment.Parent property issue Exporting Word Comments into a pdf blhowes Word 5 01-09-2010 12:31 PM

Other Forums: Access Forums

All times are GMT -7. The time now is 03:38 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft