I know this is a stupid question, but I'm at wit's end trying to figure it out.
This little snippet of code is causing a Run-time error '1004': Method 'Range' of object '_Worksheet' failed. But only when Sheet3 is not the active sheet. It does what's expected when Sheet3 is active.
With Sheet3.Range(Cells(1, 1), Cells(nrows1, ncols1))
.Clear
.Value = SCDevNeeds1
End With
Furthermore, if I change the reference to the sheet's tab name, I still get a run-time error, but this time it's an Application-defined or Object-defined error. This ALSO happens only when the sheet is not active:
With Sheets("newest").Range(Cells(1, 1), Cells(nrows1, ncols1))
.Clear
.Value = SCDevNeeds1
End With
What am I missing?