Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
Not_an_expert
 
Posts: n/a
Default Excel comments replace author

Is there a way to change Globally author in comments in Excel. ta
  #2   Report Post  
Posted to microsoft.public.excel.misc
Dave Peterson
 
Posts: n/a
Default Excel comments replace author

You'd have to use a macro.

Saved from a previous post:

Option Explicit
Sub testme01()

Dim FoundCell As Range
Dim FindWhat As String
Dim WithWhat As String

FindWhat = "ASDF"
WithWhat = "qwer"

Do
Set FoundCell = ActiveSheet.Cells.Find(What:=FindWhat, _
After:=ActiveCell, _
LookIn:=xlComments, LookAt:=xlPart, SearchOrder:=xlByRows, _
SearchDirection:=xlNext, MatchCase:=True)

If FoundCell Is Nothing Then
Exit Do
Else
FoundCell.Comment.Text _
application.substitute(FoundCell.Comment.Text, _
FindWhat, WithWhat)
End If
Loop

End Sub

application.substitute is case sensitive--so you'll have to match case.


======
If you're using xl2k or higher, you can use replace instead of
application.substitute and that can be made non-case sensitive.


Not_an_expert wrote:

Is there a way to change Globally author in comments in Excel. ta


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.misc
David McRitchie
 
Posts: n/a
Default Excel comments replace author

and to change for the future with the name you want
tools, options, General, User Name:


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel 2003 FAILS, but Excel 2000 SUCCEEDS ??? Richard Excel Discussion (Misc queries) 2 May 13th 23 11:46 AM
Excel: Add replace within selection functionality Marcel XL Excel Discussion (Misc queries) 1 March 3rd 06 02:51 PM
Change format of all comments in an Excel worksheet Eric Armstrong Excel Discussion (Misc queries) 1 February 24th 06 01:32 AM
excel encounters an error when editing comments AnnieJ Excel Discussion (Misc queries) 2 September 18th 05 06:18 PM
Excel 2002 "Protect Sheet", but Allow "Insert Comments"? VP Safe Excel Worksheet Functions 2 July 5th 05 07:18 PM


All times are GMT +1. The time now is 06:29 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"