# \#isselected

**URL:** https://community.gravityforms.com/tag/isselected/1007.md

[Latest](https://community.gravityforms.com/latest.md) · [Categories](https://community.gravityforms.com/categories.md) · [Tags](https://community.gravityforms.com/tags.md)

---

## [Pre select first option of dynamically populated radio](https://community.gravityforms.com/t/pre-select-first-option-of-dynamically-populated-radio/13878)

<div class="topic-metadata">

**Author:** [@cp5017](https://community.gravityforms.com/u/cp5017)\
**Replies:** 3\
**Last updated:** [November 17, 2022, 1:40pm UTC](https://community.gravityforms.com/t/pre-select-first-option-of-dynamically-populated-radio/13878 "2022-11-17T13:40:18Z")

</div>

isSelected’ =\> true i have added this to items array but the last item of radio is begin selected. how to select the first one?

---

## [I've set isSelected=1 on form render but this is not showing on the form \[RESOLVED\]](https://community.gravityforms.com/t/ive-set-isselected-1-on-form-render-but-this-is-not-showing-on-the-form-resolved/13291)

<div class="topic-metadata">

**Author:** [@user62f536a73c7df259](https://community.gravityforms.com/u/user62f536a73c7df259)\
**Replies:** 1\
**Last updated:** [September 13, 2022, 11:55pm UTC](https://community.gravityforms.com/t/ive-set-isselected-1-on-form-render-but-this-is-not-showing-on-the-form-resolved/13291 "2022-09-13T23:55:14Z")

</div>

I am trying to set the value of a drop-down list when a form is rendered. This is on the first page of the form. I’ve set up tests to be logged and the isSelected value is correctly changed to 1 for the option in questio…

---

## [How to change which choice in a Gravity Forms radio button field is selected using PHP as part of a gform\_pre\_submission \[RESOLVED\]](https://community.gravityforms.com/t/how-to-change-which-choice-in-a-gravity-forms-radio-button-field-is-selected-using-php-as-part-of-a-gform-pre-submission-resolved/8478)

<div class="topic-metadata">

**Author:** [@websherpa](https://community.gravityforms.com/u/websherpa)\
**Replies:** 6\
**Last updated:** [March 29, 2021, 3:41pm UTC](https://community.gravityforms.com/t/how-to-change-which-choice-in-a-gravity-forms-radio-button-field-is-selected-using-php-as-part-of-a-gform-pre-submission-resolved/8478 "2021-03-29T15:41:53Z")

</div>

I can not find a code example that works. I want to set a Product Option Radio Button Field’s selected value during a gform\_pre\_submission add\_action based on another field’s value. I’ve tried something like this (there…

---

## [Select a radio button automatically](https://community.gravityforms.com/t/select-a-radio-button-automatically/6640)

<div class="topic-metadata">

**Author:** [@user5ea97e6b9a949129](https://community.gravityforms.com/u/user5ea97e6b9a949129)\
**Replies:** 24\
**Last updated:** [December 24, 2020, 2:15am UTC](https://community.gravityforms.com/t/select-a-radio-button-automatically/6640 "2020-12-24T02:15:17Z")

</div>

Hi, after adding the values in two fields, I would like to use that value to select the default value of a radio button field. For example, if the field values are 2 and 3, I would like to have the 5 value preselected on…
