Add Comments to Cells with an Excel Macro

Add to Favorites

Add comments to cells in Excel with this macro. This allows you to quickly and easily add a comment to any cell within a worksheet or workbook in Excel.

In order to use this macro simply replace the A1 cell reference with the range object with the cell that you want to add a comment to and also replace the text This is my comment. with the text that you would like included in the comment. Make sure to put your comment within the quotation marks in the macro.

Where to install the macro:  Module

Excel Macro to Add Comments to Cells

Sub Add_Comment()
'Adds a comment to cell A1 in Excel

Range("A1").AddComment ("This is my comment.")

End Sub





Similar Content on TeachExcel
AutoFilter with an Excel Macro
Tutorial: This Excel tip shows you how you can use an Excel Macro in order to run a Filter on data w...
Add Notes and Comments to Cells in Excel
Tutorial: Did you know that you can add notes and comments to any cell in Excel?  You can write rem...
Rename a Module for an Excel Macro
Tutorial: This Excel tip shows you how to rename a module in Excel. This is a very important thing t...
Delete All Comments in a Worksheet in Excel Macro
Macro: Excel macro that will delete all of the comment contained within the active or current wor...
How to Add Formatting to Cells and Data in Excel Styles, Fonts, Colors, & More
Tutorial: In this tutorial I will cover how to use the various formatting tools in Excel. The Format...
Install a Macro into an Excel Spreadsheet
Tutorial: This tip will show you how to copy an Excel Macro into your workbook or spreadsheet. You w...



How to Install the Macro
  1. Select and copy the text from within the grey box above.

  2. Open the Microsoft Excel file in which you would like the Macro to function.

  3. Press "Alt + F11" - This will open the Visual Basic Editor - Works for all Excel Versions.  Or For other ways to get there, Click Here.

  4. On the new window that opens up, go to the left side where the vertical pane is located. Locate your Excel file; it will be called VBAProject (YOUR FILE'S NAME HERE) and click this.

  5. If the Macro goes in a Module, Click Here, otherwise continue to Step 8.

  6. If the Macro goes in the Workbook or ThisWorkbook, Click Here, otherwise continue to Step 8.

  7. If the Macro goes in the Worksheet Code, Click Here, otherwise continue to Step 8.

  8. Close the Microsoft Visual Basic Editor window and save the Excel file. When you close the Visual Basic Editor window, the regular Excel window will not close.

  9. You are now ready to run the macro.


Similar Content
AutoFilter with an Excel Macro
Tutorial: This Excel tip shows you how you can use an Excel Macro in order to run a Filter on data w...
Add Notes and Comments to Cells in Excel
Tutorial: Did you know that you can add notes and comments to any cell in Excel?  You can write rem...
Rename a Module for an Excel Macro
Tutorial: This Excel tip shows you how to rename a module in Excel. This is a very important thing t...
Excel Forum