View Single Post
  #12   Report Post  
Posted to microsoft.public.excel.programming
JLGWhiz JLGWhiz is offline
external usenet poster
 
Posts: 3,986
Default Range as Variable

I think what you are looking for is the following two lines:

x = ActiveSheet.Selection.Address
myVar = Range(x)

myVar will now contain a range reference, whether it be one cell or a group
of many cells. You can use it anywhere else in the code and it will refer to
original selected range.

"lwm" wrote:

I want to take the current range and assign it to a variable touse in
additional functions.

How do I assign the current range to a variable like X?

Thanks