I need to use the "range" parameter to select a specific cell, it happens that when I "run" the program it gives an error and says "The specified dimension is not valid for the current graph"
Error
--------------------------------------------
If Range("H(CStr(k))").Value = "" Then
-------------------------------------------
Workbooks(myRecentFile).Worksheets(counter).Range("W110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("H(CStr(k))").Paste
Workbooks(myRecentFile).Worksheets(counter).Range("AI110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("I(CStr(k))").Offset(0, 1).Paste
Else
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Select
res = res + 1
Loop
Workbooks(myRecentFile).Worksheets(counter).Range("W110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("H(CStr(k + res))").Paste
Workbooks(myRecentFile).Worksheets(counter).Range("AI110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("I(CStr(k + res))").Offset(0, 1).Paste
End If[/CODE]
Error
--------------------------------------------
If Range("H(CStr(k))").Value = "" Then
-------------------------------------------
Workbooks(myRecentFile).Worksheets(counter).Range("W110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("H(CStr(k))").Paste
Workbooks(myRecentFile).Worksheets(counter).Range("AI110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("I(CStr(k))").Offset(0, 1).Paste
Else
Do Until ActiveCell.Value = ""
ActiveCell.Offset(1, 0).Select
res = res + 1
Loop
Workbooks(myRecentFile).Worksheets(counter).Range("W110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("H(CStr(k + res))").Paste
Workbooks(myRecentFile).Worksheets(counter).Range("AI110").Copy
Workbooks("EEC QEC.xlsm").Worksheets(counter2).Range("I(CStr(k + res))").Offset(0, 1).Paste
End If[/CODE]