I keep getting a "Run-time error '1004': Application-defined or object-defined error" at this line of code:
At the time of the error WVar = 151, SVar = 3, Delete_SSCounter = 1.
And if it makes any difference, though it shouldn't, the SVar+1 column is hidden.
I can't see why I'm getting an error at this point. Any thoughts? Am I just missing an obvious coding error?
Code:
Sheets(4).Range(Cells((WVar + 2), SVar), Cells((WVar + 2 + Delete_SSCounter), (SVar + 1))).delete Shift:=xlToLeft
At the time of the error WVar = 151, SVar = 3, Delete_SSCounter = 1.
And if it makes any difference, though it shouldn't, the SVar+1 column is hidden.
I can't see why I'm getting an error at this point. Any thoughts? Am I just missing an obvious coding error?