aspose file tools*
The moose likes JSF and the fly likes getting label of selectonemenu by findcomponent Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "getting label of selectonemenu by findcomponent" Watch "getting label of selectonemenu by findcomponent" New topic
Author

getting label of selectonemenu by findcomponent

ihsan kocak
Ranch Hand

Joined: Mar 14, 2012
Posts: 31
hi, i should access a selectonemenu's selected item's label, i can get value but what about label?
Regards.
Brendan Healey
Ranch Hand

Joined: May 12, 2009
Posts: 218
I think this will do it:

UIComponent comp;
comp = ... findComponent ...
String label = (String) comp.getAttributes().get("label");

Regards,
Brendan.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: getting label of selectonemenu by findcomponent
 
Similar Threads
Label/Component/Listener
Reading value of Label
Label/Component/Listener
SWT - Wrap label
WA #1.....word association