View Single Post
  #8   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default select non contiguos columns by variable name

The cons are that you have to select something to work with it. The code is
difficult to read/modify.

The pros are that you can use what the macro recorder gave you. But that
recorded macro is probably very messy to understand.

John Keith wrote:

On Sat, 23 Jan 2010 18:14:27 -0600, Dave Peterson
wrote:

With ActiveSheet
Union(.Columns(parts), .Columns(dates), .Columns(cost)).Select
End With

But remember, it's very rare where you actually have to select a range to work
with it.


Dave,

Thank you that worked perfectly. And yes, I was able to merge the next
line that began Selection.

What are the pros/cons to using Select?

John Keith


--

Dave Peterson