Thread: Variable
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Candy[_2_] Candy[_2_] is offline
external usenet poster
 
Posts: 2
Default Variable


Hi guys,Thanks for answering my question. Really great
help! Well, I have another problem.

I need to define a range but the row number has to be a
variable. Supposed ws is defined as a worksheet and rw an
integer variable.

Here is the code:
ws.Range("A3:A" & rw & "'").Name = "range_name"

I got run-time error. Method 'Range of object'_worksheet
failed

What did I do wrong?
Thanks, again.