Win a copy of OCP Java SE 8 Programmer II Exam Study Guide this week in the OCP forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Event handling  RSS feed

Ranch Hand
Posts: 112
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Can we add an event to List?

Like say: I want to display at the ticker the content of the list which is selected.
If I select List index[0], then the content of the List at zero will be shown at the ticker and so on for which ever index I select from the List.
When I press down the down arrow of my keyboard that particular index should be displayed only and not on Pressing the Ok button which goes for the commandAction (Command c, Displayable d) method. There must be some event handling for the problem which I am facing but not sure about it.

Using this code only display the text of the first selected item which is selected by default:

If someone can please throw some lights on this.

It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!