Hi Guys,
I would like to create VBA code for : Add optional button activeX to column range K1:K15 which will be linked to cell in column A1:A15. Caption for buttons should be Select Employee
My skill in VBA is low.
I try something but not working
It can be done manualy but i will need add option button for bigger range in future.
Could you help me pls.
its urgent so i try next 2 forums :
https://www.excelforum.com/excel-pr...9309-optional-button-activex.html#post5136939
https://www.ozgrid.com/forum/forum/help-forums/excel-vba-macros/1219264-optional-button-activex
I would like to create VBA code for : Add optional button activeX to column range K1:K15 which will be linked to cell in column A1:A15. Caption for buttons should be Select Employee
My skill in VBA is low.
I try something but not working
It can be done manualy but i will need add option button for bigger range in future.
Could you help me pls.
Code:
Sub AddOptionButton()
With ActiveSheet.OLEObjects.Add(ClassType:="Forms.OptionButton.1", Left:=784, Top:=170, _
Width:=108, Height:=17)
.Name = "NewOptionButton"
.Object.Caption = "Select Employee"
End With
End Sub
Sub LinkOptionalButton()
ActiveSheet.OLEObjects("NewOptionButton").LinkedCell = "Birthday List CE!$A$1"
End Sub
its urgent so i try next 2 forums :
https://www.excelforum.com/excel-pr...9309-optional-button-activex.html#post5136939
https://www.ozgrid.com/forum/forum/help-forums/excel-vba-macros/1219264-optional-button-activex
Last edited: