# About scrollable list: can I set a value back to it?

**URL:** <https://discourse.processing.org/t/about-scrollable-list-can-i-set-a-value-back-to-it/2504>\
**Category:** Libraries\
**Created:** [August 9, 2018, 7:47am UTC](https://discourse.processing.org/t/about-scrollable-list-can-i-set-a-value-back-to-it/2504 "2018-08-09T07:47:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vapeur](https://avatars.discourse-cdn.com/v4/letter/v/f14d63/32.png) [@vapeur](https://discourse.processing.org/u/vapeur)\
**Post date:** [August 9, 2018, 7:47am UTC](https://discourse.processing.org/t/about-scrollable-list-can-i-set-a-value-back-to-it/2504/1 "2018-08-09T07:47:39Z")

</div>

Hi there, most of the times I use mouse click on scrollable list to choose whatever parameters I want. But can I set it to a value? like when I press key ‘A’ or ‘a’, the scrollable list will automatically changes to A, etc.

I’ve tried

```auto
if (keyCode == 'A' or keyCode =='a')
  {
    myParam = myList[0]; //where A is the no. 0 item
  }

```

I definitely can change the parameter myParam to A, but the change does not appear on the canvas.  
Thanks.

---

<div class="post-metadata">

**Author:** ![kfrajer](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kfrajer/32/196_2.png) [@kfrajer](https://discourse.processing.org/u/kfrajer)\
**Post date:** [August 9, 2018, 7:57am UTC](https://discourse.processing.org/t/about-scrollable-list-can-i-set-a-value-back-to-it/2504/2 "2018-08-09T07:57:21Z")

</div>

Please provide and mcve.

Kf
