View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
STEVE BELL STEVE BELL is offline
external usenet poster
 
Posts: 692
Default picking some data from a column

You might try this

Dim x as Long, cel as Range

x = 0

For each cel in Range("A1:A250") ' <<< set to your range (this could be a
variable)
If cel.Font.Bold = False then
x = x+1
End If
Next

Msgbox "The count is: " & x


To avoid blank cells use:

If cel.Font.Bold = False And Len(cel) 0 then

--
steveB

Remove "AYN" from email to respond
"guenter" wrote in
message ...

Hi, i'm trying to run some reports on an automatically generated
worksheet from our company database.

Unfortunately, the data is formatted in columns something like:

Column Title
10
8
12
5
15
..
11
9
10

The data in bold is actually the lifetime average value for the data in
the columns. I just need to run simple countif macros on the nonbolded
data, is there an easy way to grab just the data I want? I'm kinda new
to vba and excel and havn't been given much time to read up on things
so my apologies if this is obvious.


--
guenter
------------------------------------------------------------------------
guenter's Profile:
http://www.excelforum.com/member.php...o&userid=25562
View this thread: http://www.excelforum.com/showthread...hreadid=389952