# Show fields based on # of fields required (radio & conditional logic)

**URL:** <https://community.gravityforms.com/t/show-fields-based-on-of-fields-required-radio-conditional-logic/14793>\
**Category:** Get Help\
**Tags:** conditional-logic\
**Created:** [March 27, 2023, 1:59am UTC](https://community.gravityforms.com/t/show-fields-based-on-of-fields-required-radio-conditional-logic/14793 "2023-03-27T01:59:14Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![eve](https://avatars.discourse-cdn.com/v4/letter/e/9e8a1a/32.png) [@eve](https://community.gravityforms.com/u/eve)\
**Post date:** [March 27, 2023, 1:59am UTC](https://community.gravityforms.com/t/show-fields-based-on-of-fields-required-radio-conditional-logic/14793/1 "2023-03-27T01:59:14Z")

</div>

Hi guys,  
This seems like a fairly straight-forward one but I’ve been going around in circles for hours trying to get it to work.  
Basically I want to have a radio selection with 3 options:  
“How many teachers” and they can select either 1,2 or 3.  
When selecting 1, it will only show the 3 fields for "Teacher #1’, when selecting 2 it will show fields #1 and #2, and when selecting 3 it will show fields #1.#2 & #3.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/gravityforms1/original/2X/0/067894a5f62f4d3211ef959c3b4c12c8e197109a.png)

Thanks in advance for any help.

---

<div class="post-metadata">

**Author:** ![sacom](https://sea2.discourse-cdn.com/flex020/user_avatar/community.gravityforms.com/sacom/32/53_2.png) [@sacom](https://community.gravityforms.com/u/sacom)\
**Post date:** [March 28, 2023, 5:01pm UTC](https://community.gravityforms.com/t/show-fields-based-on-of-fields-required-radio-conditional-logic/14793/2 "2023-03-28T17:01:09Z")

</div>

You can do this configuring conditional logic for your fields based on the radio buttons field. See the following for more details: [https://docs.gravityforms.com/enable-conditional-logic/](https://docs.gravityforms.com/enable-conditional-logic/)

---

<div class="post-metadata">

**Author:** ![eve](https://avatars.discourse-cdn.com/v4/letter/e/9e8a1a/32.png) [@eve](https://community.gravityforms.com/u/eve)\
**Post date:** [March 28, 2023, 9:29pm UTC](https://community.gravityforms.com/t/show-fields-based-on-of-fields-required-radio-conditional-logic/14793/3 "2023-03-28T21:29:33Z")

</div>

Thanks for the reply Samuel.

I’ve tried all the various combinations of conditional logic but I’m running into a problem whereby I can get the fields to display using greater than or less than 3 but this either way around doesn’t work 100%.

Is anyone aware of a code snippet perhaps that could handle this programmatically?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex020/uploads/gravityforms1/original/2X/f/fef63f0599c45e0218c30d9f5d7ca8bff9b00189.png) [@system](https://community.gravityforms.com/u/system)\
**Post date:** [April 27, 2023, 9:29pm UTC](https://community.gravityforms.com/t/show-fields-based-on-of-fields-required-radio-conditional-logic/14793/4 "2023-04-27T21:29:53Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
