Hi all
I was wondering whether someone can help me with the following
I have a worksheet with lots of check boxes.
I have a code which looks at which checkbox is checked. This is a form control check box and not active x.
What I need is if the check box is checked then to return the value of the cell which is two rows after the checkbox.
my current code is
Sub test()
Dim cb As Excel.CheckBox
Dim Division As String
Dim shp As Shape
'Set shp = ActiveSheet.Shapes(Application.Caller)
'MsgBox shp.Name
For Each cb In ActiveSheet.CheckBoxes
If cb.Value = 1 Then
Division = cb.Offset(0, 2).Value
MsgBox "Checked"
MsgBox Division
Else
MsgBox "Unchecked"
End If
Next cb
For Each cb In ActiveSheet.CheckBoxes
cb.Value = xlOff
Next cb
End Sub
i placed a check box in B13. so of this checkbox its ticked i need the value of the cell d13.
thanks in advance
Bookmarks