# Force Default Value "\<Select One\>" in the Dropdown List

**URL:** <https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [January 2, 2022, 7:37am UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583 "2022-01-02T07:37:46Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sam.Naji](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sam.naji/32/4657_2.png) [@Sam.Naji](https://forum.inductiveautomation.com/u/Sam.Naji)\
**Post date:** [January 2, 2022, 7:37am UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583/1 "2022-01-02T07:37:46Z")

</div>

How do I force “Select One” to show up on each of the “Dropdown List” components so I can select the wildcard (\*) in my Query when there is no selection? I want the “Select One” to be the default value for the “Dropdown List” components.

I am using the “Dropdown Lists” to filter out data results in my Query. If the user does not select the value, I will bring in all the data related to the column in my table.

I am attaching an example. I hope someone can give me some help.

Thank you.

 ![Dropdown List Example](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/5/65eb531073341a079aa9e13b65d2f78189957d05.jpeg)

---

<div class="post-metadata">

**Author:** ![dkhayes117](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/dkhayes117/32/68344_2.png) [@dkhayes117](https://forum.inductiveautomation.com/u/dkhayes117)\
**Post date:** [January 2, 2022, 7:54pm UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583/2 "2022-01-02T19:54:31Z")

</div>

I think all you need to do is set `Selected Value = -1`

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [January 2, 2022, 8:10pm UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583/3 "2022-01-02T20:10:47Z")

</div>

If that doesn’t work and you’re using a script then try _None_ (Python’s _null_).

---

<div class="post-metadata">

**Author:** ![Sam.Naji](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sam.naji/32/4657_2.png) [@Sam.Naji](https://forum.inductiveautomation.com/u/Sam.Naji)\
**Post date:** [January 2, 2022, 9:06pm UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583/4 "2022-01-02T21:06:43Z")

</div>

None of the options you recommended works. I came up with a solution. I will add a Check Box for each of my selections. When it is True, I disable the selection of the dropdown list and replace its value with \*. then pass the \* to my query. Otherwise, I would use the dropdown selection value if it is not checked. See the attached example.

 ![DropdownListTemplateExample](https://us1.discourse-cdn.com/inductiveautomation/original/3X/b/5/b5c1ba929fcfcfa99cdea88f3958d54a94f679e2.jpeg)

---

<div class="post-metadata">

**Author:** ![jespinmartin1](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jespinmartin1/32/57175_2.png) [@jespinmartin1](https://forum.inductiveautomation.com/u/jespinmartin1)\
**Post date:** [January 2, 2022, 9:21pm UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583/5 "2022-01-02T21:21:20Z")

</div>

The `*` in SQL is used to call all columns from a table. Based on your explication, you're giving the wildcard a bad usage.

> [@dkhayes117](#):
>
> I think all you need to do is set `Selected Value = -1`

That is the correct answer.

You're probably confused, to force the "Default Value" you need a reset action after a selection is made. Use a reset button for example and target to `.selectedValue` and set it to -1.

Do you see that one that says 0?  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/f/9/f9484dc9e7a33af3335bdfa7469cef747e0dc096.png)

Change it to -1 in your reset action. Why -1? is because the _No Selection Value_ is -1.  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/2/0/20f099fa47ee2defb5943684733e79f653ac766b.png)

When _Selected Value_ = _No Selection Value_, you will see the _No Selection Label_

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [January 3, 2022, 1:11am UTC](https://forum.inductiveautomation.com/t/force-default-value-select-one-in-the-dropdown-list/54583/6 "2022-01-03T01:11:56Z")

</div>

> [@jespinmartin1](#):
>
> That is the correct answer.

Pretty sure on a dropdown you will need to use `.selectedIndex = -1`, not `selectedValue`. And since it isn't bindable, you probably need to use a propertyChange event monitoring `componentRunning`.
