How to assign different Linked cells to option buttons

F

furbiuzzu

Hi all,

My problem is to create more than 200 Option buttons linked to
different cells
i.e

optionbutton1.linkedcell="A1"

optionbutton2.linkedcell="A2"
.......
........

optionbutton200.linkedcell="A200"

After i've created all optionbuttons, i noticed they all have the same
linked cell
how can i assign them the right linked cell through a macro??


The problem is i have to know which line of my table has been selected
through the related option button....

thanks in advance for your help.
 
F

furbiuzzu

furbiuzzu ha scritto:
Hi all,

My problem is to create more than 200 Option buttons linked to
different cells
i.e

optionbutton1.linkedcell="A1"

optionbutton2.linkedcell="A2"
......
.......

optionbutton200.linkedcell="A200"

After i've created all optionbuttons, i noticed they all have the same
linked cell
how can i assign them the right linked cell through a macro??


The problem is i have to know which line of my table has been selected
through the related option button....

thanks in advance for your help.



Solved !!!

Sub Macro1()

For i = 1 To 268
Worksheets("Sheets1").OLEObjects("Optionbutton" & i).LinkedCell = "A"
& i + 6
Next i
End Sub
 
N

NickHK

Depending what you want to achieve, the option buttons from the Forms
toolbar return a number in the same cell, instead of True/False in their own
cells.

NickHK
 

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