Comment.AuthorInitials 属性 (PowerPoint)

返回只读的 字符串 指定 注释 对象作为作者姓名缩写。 此为只读属性。

语法

expressionAuthorInitials

表达 一个代表 Comment 对象的变量。

返回值

String

备注

此属性只返回作者的姓名首字母缩写。 若要返回作者的姓名,请使用 作者 属性。 在向演示文稿添加新批注时,请指定作者的姓名首字母缩写。

示例

下面的示例返回指定批注的作者姓名的首字母。

Sub GetAuthorName()

    With ActivePresentation.Slides(1)
        .Comments.Add Left:=100, Top:=100, Author:="Jeff Smith", _
            AuthorInitials:="JS", _
            Text:="This is a new comment added to the first slide."

        MsgBox .Comments(1).Author & .Comments(1).AuthorInitials
    End With

End Sub

另请参阅

注释对象

支持和反馈

有关于 Office VBA 或本文档的疑问或反馈? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。