# Multiple radio buttons, select one

**URL:** <https://forum.kirupa.com/t/multiple-radio-buttons-select-one/170893>\
**Category:** flash\
**Created:** [November 30, 2005, 9:26am UTC](https://forum.kirupa.com/t/multiple-radio-buttons-select-one/170893 "2005-11-30T09:26:09Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![onetwo](https://avatars.discourse-cdn.com/v4/letter/o/3d9bf3/32.png) [@onetwo](https://forum.kirupa.com/u/onetwo)\
**Post date:** [November 30, 2005, 9:26am UTC](https://forum.kirupa.com/t/multiple-radio-buttons-select-one/170893/1 "2005-11-30T09:26:09Z")

</div>

I have 5 radiobutton. They have all been grouped into the Groupname HR\_value  
Each of the radio button have the names: hr1 , hr2 and so on.

If I write: \_root.line1.vv1.hr1.selected= true I get the result i am looking for.  
But I know want this to be contingent upon the value of a variable called temp:

var temp  
temp=1  
\_root.hr[temp].selected= true

…this does unfortunately not work.

Any suggestions ?

best regards
