ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Set author for a comment? (https://www.excelbanter.com/excel-discussion-misc-queries/226023-set-author-comment.html)

Myles

Set author for a comment?
 
Is there some way to set the Author of a comment on a specific cell? I've
tried using the .author but i'm guessing that's read only.

Thanks guys!

Ron de Bruin

Set author for a comment?
 
With code you can do this
http://www.contextures.com/xlcomments03.html#Name



--

Regards Ron de Bruin
http://www.rondebruin.nl/tips.htm




"Myles" wrote in message ...
Is there some way to set the Author of a comment on a specific cell? I've
tried using the .author but i'm guessing that's read only.

Thanks guys!


Sheeloo[_4_]

Set author for a comment?
 
For an existing comment you must get the text, search and replace the author,
delete the comment and reinsert it with the updated text
..Author is a read only property
Author in the comment comes from Application.UserName

See Debra's article on 'Comments' at
http://www.contextures.com/xlcomments03.html
to learn all about comments programming.

"Myles" wrote:

Is there some way to set the Author of a comment on a specific cell? I've
tried using the .author but i'm guessing that's read only.

Thanks guys!


Myles

Set author for a comment?
 
Okay but whenever i use the

cells(1,1).addcomment "comment"

it automatically doesn't put any author in there even if i change the
Application.UserName

So how do i get it to put the author in there?

"Sheeloo" wrote:

For an existing comment you must get the text, search and replace the author,
delete the comment and reinsert it with the updated text
.Author is a read only property
Author in the comment comes from Application.UserName

See Debra's article on 'Comments' at
http://www.contextures.com/xlcomments03.html
to learn all about comments programming.

"Myles" wrote:

Is there some way to set the Author of a comment on a specific cell? I've
tried using the .author but i'm guessing that's read only.

Thanks guys!


JB

Set author for a comment?
 
Private Sub Worksheet_BeforeRightClick(ByVal Target As Range, Cancel
As Boolean)
If Target.Address = "$A$1" And Not Target.Comment Is Nothing Then
If InStr(Target.Comment.Text, Environ("username")) = 0 Then
MsgBox "Vous are not authorized!"
Exit Sub
End If
End If
End Sub

http://cjoint.com/?ebtVEAKGWV

JB
http://boisgontierjacques.free.fr

On 30 mar, 18:04, "Ron de Bruin" wrote:
With code you can do thishttp://www.contextures.com/xlcomments03.html#Name

--

Regards Ron de Bruinhttp://www.rondebruin.nl/tips.htm



"Myles" wrote in ...
Is there some way to set the Author of a comment on a specific cell? *I've
tried using the .author but i'm guessing that's read only.


Thanks guys!- Masquer le texte des messages précédents -


- Afficher le texte des messages précédents -



Sheeloo[_4_]

Set author for a comment?
 
cmt = Application.UserName
cmt = cmt & ":" & Chr(10) & "Comment"
'Delete the comment if it exists
'Cells(1, 1).Comment.Delete
Cells(1, 1).AddComment cmt

"Myles" wrote:

Okay but whenever i use the

cells(1,1).addcomment "comment"

it automatically doesn't put any author in there even if i change the
Application.UserName

So how do i get it to put the author in there?

"Sheeloo" wrote:

For an existing comment you must get the text, search and replace the author,
delete the comment and reinsert it with the updated text
.Author is a read only property
Author in the comment comes from Application.UserName

See Debra's article on 'Comments' at
http://www.contextures.com/xlcomments03.html
to learn all about comments programming.

"Myles" wrote:

Is there some way to set the Author of a comment on a specific cell? I've
tried using the .author but i'm guessing that's read only.

Thanks guys!



All times are GMT +1. The time now is 05:09 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com