ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Adding Comments (https://www.excelbanter.com/excel-discussion-misc-queries/17978-adding-comments.html)

Kim

Adding Comments
 
I want to have a macro that will add a comment box to all the cells that the
interior color index = 6. Anyone have any ideas?

TIA,

Kim

Dave O

It's pretty straightforward... what should the comment box say?


Bob Phillips

Kim,

Her is an example that works on the current selection.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Kim" wrote in message
...
I want to have a macro that will add a comment box to all the cells that

the
interior color index = 6. Anyone have any ideas?

TIA,

Kim




Bob Phillips

Well here it is

Dim c As Range

For Each c In Selection
If c.Interior.ColorIndex = 6 Then
c.AddComment c.Address
End If
Next c

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Bob Phillips" wrote in message
...
Kim,

Her is an example that works on the current selection.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Kim" wrote in message
...
I want to have a macro that will add a comment box to all the cells that

the
interior color index = 6. Anyone have any ideas?

TIA,

Kim






Kim

Perfect! Thanks!

Kim

"Bob Phillips" wrote:

Well here it is

Dim c As Range

For Each c In Selection
If c.Interior.ColorIndex = 6 Then
c.AddComment c.Address
End If
Next c

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Bob Phillips" wrote in message
...
Kim,

Her is an example that works on the current selection.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Kim" wrote in message
...
I want to have a macro that will add a comment box to all the cells that

the
interior color index = 6. Anyone have any ideas?

TIA,

Kim








All times are GMT +1. The time now is 10:08 AM.

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