Home

run time error: Can anyone see the problem with this?

Greg Bonaparte
Contributor

Can anyone see the problem with this?

 

Sub Enter_Formulas()

For r = 30 To 33
Range("$U" & r).Formula = "=SUM($Y$17-$Y$18)/($Q & r))"
Next r

End Sub

 Not sure why I get run time error

1 Reply

Hi!

Try it with that:

Range("$U" & r).Formula = "=SUM($Y$17-$Y$18)/($Q” & r &”))"

 

Some letters are missing in your posted VBA Code, like one more & und one ".  Should work now.

Hope that helps. Greets, Eva.

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
16 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
flashing a white screen while open new tab
cntvertex in Discussions on
11 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies