Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / Excel / Programming / January 2007

Tip: Looking for answers? Try searching our database.

How do I skip cells in a given range?

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
NewGuy - 30 Jan 2007 18:32 GMT
My macro calculates a large range. There are certain cells in that range that
I don't want it to include in it's performace, but I'm not sure how to get it
to skip those cells. I've tried using multiple ranges, but if I add a row
onto the worksheet, I then have to go into VBE and re-configure the multiple
ranges. HEEEELLLLPPP!!!!!
JLGWhiz - 30 Jan 2007 23:26 GMT
Using code, you would have to do it by either exclusion ( If not something or
<> something or > something or < something) or by inclusion (If = something
or Like something).  If all the ranges you want to skip are blank, for
instance, you could use:  If Not IsEmpty(Selection) then do something  :  If
the cell is blank, it would be skipped and move on to the next one.  This
approach could be used with the For...Each...Next method where each cell is
tested for the condition.

> My macro calculates a large range. There are certain cells in that range that
> I don't want it to include in it's performace, but I'm not sure how to get it
> to skip those cells. I've tried using multiple ranges, but if I add a row
> onto the worksheet, I then have to go into VBE and re-configure the multiple
> ranges. HEEEELLLLPPP!!!!!
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.