Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Checking for empty cells in a range

Hi,

Probably a silly question but I'm not sure of the best way to achieve it.

Basically, given a range (say A7:A30) what's the best way to see if any of
these cells are empty / null / blank. I don't necessarily need to know which
ones simply that there is one or more blank cell present.

Any advice, links or any other help is gratefully received.

Thanks

Chris.




  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,646
Default Checking for empty cells in a range

1. Select the range (say A7:A30)
2. Apply autofilter
3. Click down-arrow at Cell A7
4. Check in the list if there is the word "empty"
5. Clicking "empty" you will see the empty cells

Regards,
Stefi


€˛Chris Strug€¯ ezt Ć*rta:

Hi,

Probably a silly question but I'm not sure of the best way to achieve it.

Basically, given a range (say A7:A30) what's the best way to see if any of
these cells are empty / null / blank. I don't necessarily need to know which
ones simply that there is one or more blank cell present.

Any advice, links or any other help is gratefully received.

Thanks

Chris.





  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Checking for empty cells in a range


Sub check_cells()

Dim cell As Range
Dim a As Long

For Each cell In Range("a1:b10")
If cell.Value = "" Then a = a + 1
Next cell

MsgBox "Number of empty cells in range: " & a

End Sub


--
sihvonma
------------------------------------------------------------------------
sihvonma's Profile: http://www.excelforum.com/member.php...o&userid=16511
View this thread: http://www.excelforum.com/showthread...hreadid=380478

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 93
Default Checking for empty cells in a range

=SUMPRODUCT(--(ISBLANK(A7:A30)--(ISBLANK(C7:C30))))

could be all right for you if the ranges are the same size, note that

=SUMPRODUCT(--(ISBLANK(A7:A30)--(ISBLANK(C7:C35)))) doesn´t work.

Then it´s OK to use

=SUMPRODUCT(--(ISBLANK(A7:A30)))+SUMPRODUCT(--(ISBLANK(C7:C35)))

Enjoy!

Reply
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
delete all empty cells in a range Gary Excel Worksheet Functions 2 February 8th 07 09:09 PM
Checking Range of Cells on Multiple Worksheets in the same workboo Ramesh.S, India Excel Discussion (Misc queries) 1 October 12th 06 09:46 AM
Checking for empty cells in a range Chris Strug Excel Programming 8 June 21st 05 12:07 AM
Checking for empty cells in a range Chris Strug Excel Worksheet Functions 2 June 20th 05 10:33 AM
sum next two non-empty cells in a range Spencer Hutton Excel Worksheet Functions 1 January 9th 05 11:29 PM


All times are GMT +1. The time now is 09:43 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"