View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
keepITcool keepITcool is offline
external usenet poster
 
Posts: 2,253
Default Is there a way to remove a range from within another range?


your SpecialCells approach is correct. and No alternative


a while back i've been looking into this but couldn't find anything like
SUBTRACT or EXCLUDE to complete the family of INTERSECT and UNION Methods


I could be so easy to implement, but native Excel only.
else you need so many loops it's way to slow.

maybe in Excel14.. VB.Net etc etc etc... around 2020 i'd think.



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


Dave wrote:


I'v written a routine to select all the used cells on a sheet by using
Union on the SpecialCells xlConstants & xlFormulas ranges. This code
needs a chunk of error handling in case either of these two ranges do
not exist.

This works fine but I was wondering if there was an easier way such as
simply removing the SpecialCells xlBlanks from the Usedrange, ie the
inverse of a Union procedure?

Cheers

Dave



*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!