Find blank cell in range


"Excel VBA Help"

 


Play Friv Now - Play Friv Games
Go Back   The Code Cage Forums > Microsoft Topics > Microsoft Excel Forum
Our Info Pages:-
The Code Cage - Microsoft Office help

Notices

Microsoft Excel Forum Members Post questions in this forum if they are related to using Microsoft Excel, this includes Worksheet Functions, Excel VBA Programming, Simple Macro Code & Charting, Excel formula etc.

New Reply
Thread Tools Rate Thread Display Modes
  #1  
Unread 12th October 2009, 19:35
CR's Avatar
CR
Newsgroup Contributor
 
Posts: n/a
Posts Per Day: 0
My Top Tip Count:
Default Find blank cell in range
     Excel: VBA   


I have a variable range, D4: to either- Q, R, S, or T4

I find that range with



lastCol = Range("D4").End(xlToRight).Select



Then I name MyRange in row 5



ActiveCell.Offset(1, 0).Select

Set endcell = ActiveCell

Set MyRange = Range("D5:" &
endcell.Address)



This seems to work (maybe not the best way?)



The cells in MyRange have values that could be from 0 to 100.



I need to search through each cell in MyRange until it finds one that has no
value (blank cell, not a 0 value) If a blank cell is found, I want a msgbox
to tell me.



(I don't even need to know where it is. It just lets me know that all values
are not entered yet and lets me work with the values that are.)



Once one empty cell is found, the msgbox displays, the search stops, and
goes to the rest of my sub. If none is found the sub just continues.



I thank you great people in advance

CR



The Code Cage Advertisment
Advertisement
  #2  
Unread 12th October 2009, 19:56
Gary''s Student's Avatar
Gary''s Student
Newsgroup Contributor
 
Posts: n/a
Posts Per Day: 0
My Top Tip Count:
Default RE: Find blank cell in range

------ Register to get rid of these "In Post" ads! ------


Warning

Warning



Sorry but you need to register for FREE to see the rest of these posts. Please click HERE to register.

We only allow guests to see the first post of every thread to keep valuable resources for our members.






  #3  
Unread 12th October 2009, 20:00
JLGWhiz's Avatar
JLGWhiz
Newsgroup Contributor
 
Posts: n/a
Posts Per Day: 0
My Top Tip Count:
Default Re: Find blank cell in range

------ Register to get rid of these "In Post" ads! ------


Warning

Warning



Sorry but you need to register for FREE to see the rest of these posts. Please click HERE to register.

We only allow guests to see the first post of every thread to keep valuable resources for our members.






The Code Cage Advertisment
Advertisement
  #4  
Unread 12th October 2009, 20:03
ker_01's Avatar
ker_01
Newsgroup Contributor
 
Posts: n/a
Posts Per Day: 0
My Top Tip Count:
Default RE: Find blank cell in range

------ Register to get rid of these "In Post" ads! ------


Warning

Warning



Sorry but you need to register for FREE to see the rest of these posts. Please click HERE to register.

We only allow guests to see the first post of every thread to keep valuable resources for our members.






  #5  
Unread 12th October 2009, 20:33
CR's Avatar
CR
Newsgroup Contributor
 
Posts: n/a
Posts Per Day: 0
My Top Tip Count:
Default Re: Find blank cell in range

------ Register to get rid of these "In Post" ads! ------


Warning

Warning



Sorry but you need to register for FREE to see the rest of these posts. Please click HERE to register.

We only allow guests to see the first post of every thread to keep valuable resources for our members.






The Code Cage Advertisment
Advertisement
New Reply
The Code Cage at Facebookhe Code Cage at Twitter


Tags
blank, cell, range

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

The Code Cage Affilliates



http://www.thecodecage.com/forumz tested by McAfee Security http://www.thecodecage.com/forumz tested by McAfee Security

All times are GMT +1. The time now is 10:06.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Template-Modifications by TMS
No part of this board, functionality or creatives may be copied or reproduced either in part or full without the express permission of The Code Cage Team.
Copyright ©2008 - , Simon lloyd.
We are not associated with nor employed by Microsoft in any way, we simply provide resources!
All MS office icons are registered trademarks of the application they represent and are used with permission from Microsoft
UA-8135493-1
Cultural Forum | Study at Malaysian University