Ark68
Well-known Member
- Joined
- Mar 23, 2004
- Messages
- 4,564
- Office Version
- 365
- 2016
- Platform
- Windows
Someone helped me create this line of code to assign a name to a range.
Instead of assigning this range to a named range, I want to assign a variable to it. I am hoping someone can assist in adapting this code appropriately.
I know my interpretation is incorrect (in red above) as I'm receiving a syntax error.
Rich (BB code):
Workbooks("Sports17.xlsm").Names.Add Name:="data_file_list", RefersTo:="=OFFSET('[" & wb_sched.Name & "]" & temp_ws.Name & "'!$B$1,1,0,count('[" & wb_sched.Name & "]" & temp_ws.Name & "'!$A:$A),2)"
Instead of assigning this range to a named range, I want to assign a variable to it. I am hoping someone can assist in adapting this code appropriately.
Rich (BB code):
Dim rdfl as range
Set rdfl = OFFSET('[" & wb_sched.Name & "]" & temp_ws.Name & "'!$B$1,1,0,count('[" & wb_sched.Name & "]" & temp_ws.Name & "'!$A:$A),2)
I know my interpretation is incorrect (in red above) as I'm receiving a syntax error.