View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Dr. Schwartz[_3_] Dr. Schwartz[_3_] is offline
external usenet poster
 
Posts: 10
Default Assigning values from a selected range to individual variables

A user selects a range (eg: Range("A1:C1")) and runs a macro. The macro should then assign the value from each cell to its own variable. So cell A1 = 2, B1 = 4 and C1 = 6 and the variables should end up with NumA = 2, NumB = 4 and NumC = 6.

The problem is that I want to be able to handle any size of selected range the user would make and then assign the given number of values to an individual variabel.

Can anybody help out?

Thank you
Schwartz