Aerowolf
Programmer
- Nov 6, 2002
- 64
Here's my code:
Dim nm As String, nbr As String, due As String, ord As String
nbr = ActiveCell.Offset(0, 1).Range("A1")
due = ActiveCell.Offset(0, 9).Range("A1")
ord = ActiveCell.Offset(0, 13).Range("A1")
nm = "X:\WOVEN PRODUCTION\CRIMP & WEAVE INST & ROUTINGS\" & ActiveCell & ".xls"
Workbooks.Open nm, 3, False
With Workbooks(nm)
Range("R2").Value = nbr
Range("M5").Value = due
Range("H7").Value = ord
End With
I'm getting a subscript out of range error on the With Workbooks(nm) line. Help!
Dim nm As String, nbr As String, due As String, ord As String
nbr = ActiveCell.Offset(0, 1).Range("A1")
due = ActiveCell.Offset(0, 9).Range("A1")
ord = ActiveCell.Offset(0, 13).Range("A1")
nm = "X:\WOVEN PRODUCTION\CRIMP & WEAVE INST & ROUTINGS\" & ActiveCell & ".xls"
Workbooks.Open nm, 3, False
With Workbooks(nm)
Range("R2").Value = nbr
Range("M5").Value = due
Range("H7").Value = ord
End With
I'm getting a subscript out of range error on the With Workbooks(nm) line. Help!