do you have programming experts in Visual Basic (Excel)?

Job ID: 33853441

Budget: $30 – $250 AUD

I’ve got a small task for you that is a bit different.
 
The Excel template of the comment sheets they use on this project contain merged cells in some of the rows. (In my opinion they should be banned from Excel).
 
Normally when a cell in a row has more text than will fit and ‘wrap text’ is turned on, you can double click on the row line to auto-resize the row height so all the lines of the text are visible.
Double click on the line between 17 and 18 and it should expand.
 
This also works normally with multiple rows selected. However, when there are merged cells in the row, this function does not work and just resizes the rows to a single line of text, hiding all the other lines of text in the cells.
Very unfortunately, the project template comment sheets have lots of merged cells, and dozens of cells with multiline text, so we have to resize each row manually to read it. Which is a total pain.
See attached example.
 
a macro in VBA in Excel has already been written to automatically resize all the rows in this template spreadsheet, however firstly I have lost the macro file somehow, and secondly it didn’t work very well.

The task is:
 
Do you think you can have a go a writing a new macro to do it?
Maybe you could make a very simple one to choose row heights based on how many letters are in the cell contents.
 
It gets a bit complicated to do it perfectly with font sizes and zoom levels and things to know how tall the row needs to be.
My method was actually copying the cell contents one by one to a blank worksheet and using the auto-resize feature on that row, then copying the new row height back to the original cell. It was a bit slow though as it had to loop through all the rows in the sheet.
 
If you can make it so you first select the cells you want to use to resize the rows, that would make it useful for other spreadsheets. 
Related categories: Visual Basic