removing pre-set characters from comments

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi everyone, for some reason I have a few misc. characters that appear at the
start of each comment box I open. In order to make a nice clean neat comment
I have to delete them every time I create a new comment. Any idea how to
permanantly clear the comment box?
 
Matt

You can get rid of all but the colon (:) if you go to Tools>Options>General
and delete the user name.

Replace with one space.

The only way to get a fully blank comment box is to use VBA.

This from Debra Dalgleish.

Sub PlainComment()
Selection.AddComment text:=""
Selection.Font.FontStyle = "Regular"
Selection.Comment.Visible = True
End Sub

Assign to a Toolbar button


Gord Dibben Excel MVP
 
Thank you for the quick response and perfect answer to my question. I have it
down to just the " : " now but I'd be interested in using the VBA idea for
making the box totally blank. If it's not too much trouble could you give me
a quick run down on how/where to add the script to accomplish this?
 
Matt

If not familiar with VBA and macros, see David McRitchie's site for more on
"getting started".

http://www.mvps.org/dmcritchie/excel/getstarted.htm

In the meantime..........

To create a General Module, hit ALT + F11 to open the Visual Basic Editor.

Hit CRTL + R to open Project Explorer.

Find your workbook/project and select it.

Right-click and Insert>Module. Paste the PlainComment code in there. Save
the workbook and hit ALT + Q to return to your workbook.

Run the macro by going to Tool>Macro>Macros.

To assign to a button on your Toolbar........

Tools>Customize>Commands

Scroll down to and select Macros.

Drag the smiley face button to a Toolbar. Right-click on it and "assign
macro".

Pick the PlainComment macro and OK.


Gord
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top