#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 100
Default I'm loving Interse

I really like the Intersect function. I use it a lot, for instance if my VBA wants to process every row that the user has selected:

Set ProcessRange = Intersect( ActiveSheet.UsedRange, Selection.EntireRow, Cells(1,1).EntireColumn )

It also removed duplciate selected cells. ProcessRange.Count tells me how many rows are selected.

Any time you process a set of selected cells, Intersect( Selection, ActiveSheet.UsedRange ) will remove thousands of redundant cells that you don't need to process.

Phil.
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



All times are GMT +1. The time now is 05:09 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"