添加回复评论 [英] Add reply to comment

查看:87
本文介绍了添加回复评论的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



您好, 



在我的Word文档中,我有很多评论,我希望通过点击按钮添加回复,并附上一些文字



-------

    I   有一个带按钮的UserForm:
$


    previous_comments    // Selection.GoTo What:= wdGoToComment,其中:= wdGoToPrevious,Count:= 1,Name:=""

    next_comments        // Selection.GoTo What:= wdGoToComment,其中:= wdGoToNext,Count:= 1,Name:=""
$


    Text_button_1,text_button_2,text_button_3 ... text_button_9
$


   退出

-------



$
我想在评论中添加回复我选择单击上一个和下一个按钮



我有:

Text_button_1 // Selection.Collapse Direction:= wdCollapseEnd ActiveDocument.Comments(1 ).Replies.Add Range:= Selection.Range,Text:=" Reply 1" 



这个添加对第一条评论的回复,但我不知道知道如何通过上一个或下一个点击按钮回复我选择的评论。 

我不知道如何计算评论并更改ActiveDocument.Comments中的索引(?这?)。



(我使用Word 2016)




解决方案

您好rputt,


您可以使用
Selection.Comments


以下是示例。

 Private Sub tbnAddComment_Click()

Dim cmt As Comment

If Application.Selection.Comments.Count> 0然后

设置cmt = Application.Selection.Comments(1)

cmt.Replies.Add cmt.Range," Reply 1"

结束如果

结束子

最好的问候,


Terry


Hello, 

On my Word document I have many comments and i want add reply by click button with some text

-------
    I   have a UserForm with buttons:

    previous_comments   // Selection.GoTo What:=wdGoToComment, Which:=wdGoToPrevious, Count:=1, Name:=""
    next_comments       // Selection.GoTo What:=wdGoToComment, Which:=wdGoToNext, Count:=1, Name:=""

    Text_button_1, text_button_2, text_button_3 ... text_button_9

    exit
-------


I want to add a reply to the comments I chose by clicking the previous and next buttons

I have:
Text_button_1 // Selection.Collapse Direction:=wdCollapseEnd ActiveDocument.Comments(1).Replies.Add Range:=Selection.Range, Text:="Reply 1" 

this add reply to first comment, but i don't know how to reply to the comment I chose by click button previous or next. 
I dont know how count comments and change the index in ActiveDocument.Comments(?this?).

(I use Word 2016)


解决方案

Hi rputt,

You could use Selection.Comments to get the current selected comments.

Here is the example.

Private Sub tbnAddComment_Click()

Dim cmt As Comment

If Application.Selection.Comments.Count > 0 Then

Set cmt = Application.Selection.Comments(1)

cmt.Replies.Add cmt.Range, "Reply 1"

End If

End Sub

Best Regards,

Terry


这篇关于添加回复评论的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆