title: Count rows for merged cells
body: <p>I have a problem to count the number of rows for each block of merged cells, in Excel.</p>
  
  <p>I have a value on A1. If I merge cells A1 to A4 the value appears centered, on the range A1-A4.
  Then I have another value in A5. If I merge cells A5 to A12, this second value appears centered on this second block of cells.</p>
  
  <p>What I want is to count number of rows for each block of merged cells.</p>
  
  <p>I have tried to use VBA programming to detect these number of rows, with function "MergeArea" and "CurrentRegion.Count" but the program detects that the two blocks are contiguous and counts 12 rows, instead of 4 and then 8.
  If it detects "4" first, I could put the correct instruction on a loop and then detect "8".</p>