Jun 14 2020 08:58 AM
Although I have successfully ran similarly coded macros, this particular one is driving me crazy. Below is the code,
Sub MoonSpeedNew()
Worksheets("Sheet4").Activate
Set r1 = Range("MoonVariables")
Set r2 = Range("day**bleep**spvalue")
Set r3 = Range("Resultvariables")
Dim Highlimit As Single
Dim oldlimit As Single
Dim Lowlimit As Single
Dim limit As Single
Dim Diff As Single
Dim imax As Integer
Dim i As Integer
The macro hangs up at the statement
Set r1 = Range("MoonVariables")
with the above runtime error 1004
I checked the Range for MoonVariables under Name Manager in excel ...looks okay to me.
Jun 14 2020 09:31 AM
Sorry, I found my mistake. I was referring to the wrong sheet. My apologies. @Jmaheshri
Jun 14 2020 09:38 AM
There may be one of the two issues....