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

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

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.

Please provide and mcve.