Greetings,
I have several ActiveX Control Check Boxes I need to create, all using the same code. I can copy and paste the Sub name into the code, but this will take a very long time, not to mention the chance of errors. I have tried using a DIM statement to insert the Sub name into the code, but cannot figure it out.
Below is the code i am using.
Private Sub cbCSsowFence_Click()

If Sheet9.Range("j57") <> "1" Then Exit Sub

If cbCSsowFence.Value = True Then
    Sheet1.Range("G821").Value = "True"
    cbCSsowFence.BackColor = &HFF&
    cbCSsowFence.ForeColor = &HFFFFFF
    cbCSsowFence.Value = True
    Range("J1").Select

ElseIf cbCSsowFence.Value = False Then
    Sheet1.Range("G821").Value = "False"
    cbCSsowFence.BackColor = &H50D092
    cbCSsowFence.ForeColor = &H0&
    Range("J1").Select
    
    End If

End Sub