I have two worksheets in excel and I am trying to copy a value from one and paste it into a specific cell in the other. I have managed to select the other worksheet and copy the value, and even select back into the other one but for whatever reason I cannot paste the value back in, let alone even select that box! When I add in that part off the code it gives me the error "Run-time error: '438': Object doesn't support this property or method.
I even recorded macro to try and see what it would give me to select the cell and it gave me the exact same thing which was "Range("G4").Select
Here is my code: Sub State_Selector()
Dim x As Integer
For x = 2 To 54
If Cells(x, 1) = Sheets("Sheet1").Cells(4, 3) Then
Worksheets("Data").Cells(x, 8).Copy
Worksheets("Sheet1").Select
Range("G4").Paste
End If
Next x
End Sub
I have tried to run the code now many times, please help!