LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 38
Default Counting Merged Cells

I am using 2003 and counting colored blank cells. The range is several rows
with some rows containing 4 column cells (ie A1, B1, C1, D1) and other rows
with only 2 column cells having merged A1 and B1 into one cell with C1 and D1
into a second merged cell.
I need the merged cells to only count as one. Currently they count as 2
when I run the following:

Sub standard()
Set myrange = Range("A1:D20")
For Each c In myrange
If c.Interior.ColorIndex = 6 Then
yellowcells = yellowcells + 1
End If
Next
MsgBox yellowcells
End Sub


I am not an expert macro writer so I hope this makes sense :J
Thanks in advance for any help.

Clint
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Autofit Merged cell Code is changing the format of my merged cells JB Excel Discussion (Misc queries) 0 August 20th 07 02:12 PM
Counting values across merged cells. BRYAN J MCGLADE Excel Discussion (Misc queries) 0 November 17th 06 01:04 AM
how do i link merged cells to a merged cell in another worksheet. ibbm Excel Worksheet Functions 3 April 27th 06 11:40 PM
Errors in COUNT, COUNTA, COUNTIF when counting merged cells Outback Excel Worksheet Functions 1 February 7th 06 04:29 PM
Sorting merged cellsHow do I sort merged cells not identically siz Laval Excel Worksheet Functions 1 November 3rd 04 09:40 PM


All times are GMT +1. The time now is 04:36 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"