I have a List of items, along with a menu of commands, each command depending on the item selected in the list. But when I click on any of the commands in the menu, it is always the first item in the menu that gets selected. Why is this so and what is the solution to it?