# Dropdown dataset refresh

**URL:** <https://forum.inductiveautomation.com/t/dropdown-dataset-refresh/51024>\
**Category:** Ignition\
**Created:** [September 16, 2021, 12:43am UTC](https://forum.inductiveautomation.com/t/dropdown-dataset-refresh/51024 "2021-09-16T00:43:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![david.bath](https://avatars.discourse-cdn.com/v4/letter/d/898d66/32.png) [@david.bath](https://forum.inductiveautomation.com/u/david.bath)\
**Post date:** [September 16, 2021, 12:43am UTC](https://forum.inductiveautomation.com/t/dropdown-dataset-refresh/51024/1 "2021-09-16T00:43:49Z")

</div>

Im using a library script to generate a dataset for a dropdown component using runscript() in the expression binding for the dropdown.data item.  
The script cycles through a set of tags and adds values to the dataset based on some conditions.  
This all works fine when the popup window is opened.

The popup window displays and allows manipulation of a PLC UDT item.  
When this PLC data is modified and “Saved”, I want the dataset in the dropdown to refresh (i.e. rerun the script that is bound to the dropdown data item).  
How do I do this?

---

<div class="post-metadata">

**Author:** ![jlandwerlen](https://avatars.discourse-cdn.com/v4/letter/j/bc8723/32.png) [@jlandwerlen](https://forum.inductiveautomation.com/u/jlandwerlen)\
**Post date:** [September 16, 2021, 1:36am UTC](https://forum.inductiveautomation.com/t/dropdown-dataset-refresh/51024/2 "2021-09-16T01:36:25Z")

</div>

You want to use `system.db.refresh`, example in link, instead of table you will use reference to the dropdown component, still use ‘data’ though.  
[https://docs.inductiveautomation.com/display/DOC81/system.db.refresh](https://docs.inductiveautomation.com/display/DOC81/system.db.refresh)

---

<div class="post-metadata">

**Author:** ![david.bath](https://avatars.discourse-cdn.com/v4/letter/d/898d66/32.png) [@david.bath](https://forum.inductiveautomation.com/u/david.bath)\
**Post date:** [September 17, 2021, 1:08am UTC](https://forum.inductiveautomation.com/t/dropdown-dataset-refresh/51024/3 "2021-09-17T01:08:16Z")

</div>

thanks @jlandwerlen works perfectly.  
added this to the focusGained script for the dropdown so that the dropdown is always refreshed.
