- 增加批注
Sub 新增批注()
'Chr(10) 代表 换行符
Range("B3").AddComment
Range("B3").Comment.Text Text:="新增批注:" & Chr(10) & "123"
End Sub
- 显示/隐藏批注 (Comment.Visible)
Sub 显示或隐藏批注()
'显示批注
Range("b2").Comment.Visible = True
'隐藏批注
Range("b2").Comment.Visible = False
End Sub
- 删除批注 (ClearComments)
Sub 删除批注()
'删除批注
Range("B2").ClearComments
End Sub