Count Number of Lines Within a Cell

seguin85

Active Member
Joined
Mar 17, 2015
Messages
278
Office Version
  1. 365
Platform
  1. Windows
Hi,
Is there a way to count the number of lines within a cell? I found a formula and VBA to count the line breaks which is great, but I need something that will also count when a wrapped text goes to the next line.

It may be important to note that the cells are merged...

Thanks in advance!
 
I didn't think it would be that difficult of a task, but I am very appreciative of the feedback
 
Upvote 0

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
I didn't think it would be that difficult of a task
It's not that difficult if the merged cells are removed from the equation.
You could try educating the person that asked you to do this in the art of designing sheets without merged cells, although such a task is usually as impossible as working with merged cells ?
 
Upvote 0
It's not that difficult if the merged cells are removed from the equation.
You could try educating the person that asked you to do this in the art of designing sheets without merged cells, although such a task is usually as impossible as working with merged cells ?

Thanks, I ended up reformatting the sheet to not have merged cells to help with this issue. It doesn't look quite as pretty as it used to, but it functions much better now.
 
Upvote 0

Forum statistics

Threads
1,215,233
Messages
6,123,771
Members
449,122
Latest member
sampak88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top