GuyHamasaki
MIS
I need to define an Excel Name in a macro. The Name is created in the macro as follows: ActiveWorkbook.Names.Add Name:="Test", RefersToR1C1:="=Test!R1C1:R1567C66"
I have created 2 string variables--one to capture the number of columns and the other to capture the number rows. I set these variables as follows.
strColumns = Range("A1".End(xlToRight).Column
strRows = Range("A1".End(xlDown).Row
How do I insert strRows where 1567 is and strColumns where 66 is?
I would also like to set ActiveWorkbook.Names.Add Name:="Test", RefersToR1C1:="=Test!R1C1:R1567C66" equal to another string variable, let's call it str1 for this example. How can this be done?
Thanks in advance,
Guy
I have created 2 string variables--one to capture the number of columns and the other to capture the number rows. I set these variables as follows.
strColumns = Range("A1".End(xlToRight).Column
strRows = Range("A1".End(xlDown).Row
How do I insert strRows where 1567 is and strColumns where 66 is?
I would also like to set ActiveWorkbook.Names.Add Name:="Test", RefersToR1C1:="=Test!R1C1:R1567C66" equal to another string variable, let's call it str1 for this example. How can this be done?
Thanks in advance,
Guy