# List of fixed values in the UI for a subflow

**URL:** https://discourse.nodered.org/t/list-of-fixed-values-in-the-ui-for-a-subflow/40161
**Category:** General
**Created:** [1 February 2021 10:41 UTC](https://discourse.nodered.org/t/list-of-fixed-values-in-the-ui-for-a-subflow/40161 "2021-02-01T10:41:43Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![fmarzocca](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/fmarzocca/32/35901_2.png) [@fmarzocca](https://discourse.nodered.org/u/fmarzocca)
#### Post date: [1 February 2021 10:41 UTC](https://discourse.nodered.org/t/list-of-fixed-values-in-the-ui-for-a-subflow/40161/1 "2021-02-01T10:41:43Z")

</div>

Hi,  
I need to show a list of fixed values as string inputs in the UI of a subflow:

![Schermata 2021-02-01 alle 11.37.14](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/0/0/008384ef229298eb7f8c1f2d1f32d9291b01b971.png)

The user should select one out of 10 fixed values for DEVICE, in a dropdown list.  
How can I do?

---

<div class="post-metadata">

### Author: ![bakman2](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bakman2/32/6207_2.png) [@bakman2](https://discourse.nodered.org/u/bakman2)
#### Post date: [1 February 2021 11:10 UTC](https://discourse.nodered.org/t/list-of-fixed-values-in-the-ui-for-a-subflow/40161/2 "2021-02-01T11:10:21Z")

</div>

There are multiple options.

 ![Screenshot 2021-02-01 at 12.08.53](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/f/1/f19a2619df967794e216cd97cd08fa75261099b2.jpeg)

Make sure to [go through the documentation](https://nodered.org/docs/user-guide/editor/workspace/subflows).

---

<div class="post-metadata">

### Author: ![droberts](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/droberts/32/40295_2.png) [@droberts](https://discourse.nodered.org/u/droberts)
#### Post date: [1 February 2021 11:15 UTC](https://discourse.nodered.org/t/list-of-fixed-values-in-the-ui-for-a-subflow/40161/3 "2021-02-01T11:15:37Z")

</div>

As Bakman says, once you have created the variable, click the down arrow next to its name.

Select 'Select' from the input type dropdown.

Once you have done this, click the furthest right dropdown and you will get an add element ui. Below is an example subflow you can import.

```auto
[{"id":"bc04e851.d49ed8","type":"subflow","name":"Subflow 1","info":"","category":"","in":[],"out":[],"env":[{"name":"DeviceNo","type":"str","value":"Dev1","ui":{"icon":"font-awesome/fa-laptop","type":"select","opts":{"opts":[{"l":{"en-US":"Device 1"},"v":"Dev1"},{"l":{"en-US":"Device 2"},"v":"Dev2"},{"l":{"en-US":"Device 3"},"v":"Dev3"}]}}}],"color":"#DDAA99","status":{"x":160,"y":30,"wires":[]}},{"id":"6f86169.b529de8","type":"debug","z":"bc04e851.d49ed8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":360,"y":80,"wires":[]},{"id":"43b1d3cf.f08e5c","type":"inject","z":"bc04e851.d49ed8","name":"","props":[{"p":"payload"}],"repeat":"1","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"DeviceNo","payloadType":"env","x":220,"y":80,"wires":[["6f86169.b529de8"]]},{"id":"1738eaf6.f5d395","type":"subflow:bc04e851.d49ed8","z":"ced96e30.86933","name":"","env":[{"name":"DeviceNo","value":"Dev2","type":"str"}],"x":480,"y":540,"wires":[]}]

```

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/4/840192c3d988e85d8e82309b7b7812eebbc0e913.png)

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [15 February 2021 11:16 UTC](https://discourse.nodered.org/t/list-of-fixed-values-in-the-ui-for-a-subflow/40161/4 "2021-02-15T11:16:06Z")

</div>

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