using checkbox to calculate another cell

G

Guest

I have the following code in a macro for a checkbox and it gives a error of
object required any suggestions?


Private Sub CheckBox19_Click()
If CheckBox19.Value = True Then
Range("I24").Select
ActiveCell.FormulaR1C1 = "=0.07*R[-1]C"
Else: Range("I24").Select
Selection.Value = 0
End If
End Sub
 
G

George

Assue you use control Check box with cell link of "J7", try

Sub CheckBox19_Click()


If Range("j7").Value = True Then
Range("I24").Select
ActiveCell.FormulaR1C1 = "=0.07*R[-1]C"
Else
Range("I24").Select
Selection.Value = 0
End If
End Sub

George
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top