Resize Only the Comments You Select, Not the Whole Sheet

If you want to run a macro that resizes comments only on selected cells, you’ll need to adjust your existing code.

3 min readMicrosoft Excel | Help & Support with your Formula, Macro, and VBA problems | A Reddit Community

There's a quiet frustration that builds when you're deep in a spreadsheet, resizing comment boxes one by one, knowing full well there's a faster way. The user who posted this macro isn't asking for a miracle, they're asking for precision. Their script works, but it works too broadly, touching every comment on the sheet when all they want is to adjust the ones tied to cells they've actually selected. That's not a trivial request. It's the difference between a tool that serves you and a tool that makes you serve it.

The fix they need is straightforward, and that's exactly why it matters. Instead of looping through `Application.ActiveSheet.Comments`, the macro should loop through the comments attached to the selected range. In VBA, that means checking each cell in `Selection` for a comment, then resizing only those shapes. A simple `If Not c.Comment Is Nothing Then` guard does the heavy lifting. It's a small change in code, but it transforms the macro from a blunt instrument into a surgical one. You stop being the person who resizes everything and then undoes the damage. You become the person who touches only what they intend to touch.

This is the kind of adjustment that separates a workable script from a genuinely useful one. The original macro isn't wrong, it's just indiscriminate. And in a world where spreadsheets are already dense with data, the last thing you need is a tool that adds more friction. By scoping the action to the selected cells, you're not just saving a few clicks. You're reducing the cognitive load of the task itself. You're making the tool feel responsive to your intent, rather than forcing you to conform to its broad strokes.

So here's the practical takeaway: if you're going to automate a repetitive task, automate it with boundaries. The user's instinct to write a macro was right. The next step is to refine it so it respects the context of your work. Check if the cell has a comment. Resize only that one. Move on. That's not just better code, it's a better way of thinking about automation. It's the difference between a script that runs and a script that works the way you do.

From Microsoft Excel | Help & Support with your Formula, Macro, and VBA problems | A Reddit Community

I have macro that changes to size of comments. Can anyone help me to adjust it so it only runs on selected cells? Much appreciated!

Read the original at Microsoft Excel | Help & Support with your Formula, Macro, and VBA problems | A Reddit Community