empty variable range

  • Thread starter Thread starter S1
  • Start date Start date
S

S1

hi all,
I posted this yesterday but i failed to mention something
and the advise i got is not working. my fault.
how can i tell if a range is empty.
i have a do loop that i want to check a range as it goes
down the sheet. if the range is empty then color it else
don't. the range is assigned to a variable as it moves
down the sheet.
what i am using now is
application.counta("qpa1")
this counts 1 regardless of what is in the range.
anyone have hints, suggestions, directions?
any help would be appreciated.
S1
 
thank you Bob
S1
-----Original Message-----
Maybe

If Application.CountA(Range("J12:X12"))> 0 Then
...

--

HTH

RP
(remove nothere from the email address if mailing direct)





.
 
There must be something in the range if it is 1.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 
hi bob
I high lighted the range and deleted. but even in the
other ranges(as it moves down the sheet) it will return 1
even if there are 3,4 or 5 number in the range. it returns
1 regardless.
 
hi,
i did some research.
Counta is for text/other
count is for numbers
however changing to count and formating all the qpa's to
number does no good either.
aplication.count("qpa1") now returns zero regarless of
what is in the range.
 
Want to send me the workbook, and I can take a look.

--

HTH

RP
(remove nothere from the email address if mailing direct)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top