Is it possible to get component associated with DefaultListSelectionEvent?

Hallo,
Is it possible to get component associated with DefaultListSelectionEvent, please?
There are multiple tables in my window. All tables (must!) have same TableSelectionListener. Problem is that there's no information about component in default list selection model implementation. When fireing events DefaultListSelectionModel use self as event source (see DefaultListSelectionModel.fireValueChanged fragment below).
e = new ListSelectionEvent(this, firstIndex, lastIndex, isAdjusting);Any ideas how to get component in ListSelectionListener.valueChanged, please? But don't forget that as a programer, i am the lazy. Thus implementing new selection model is not an acceptable solution, but class extension is :p
One idea is to remember models component in constructor and override DefaultListSelectionModel.fireValueChanged like this:
class MyGreatListSelectionModel extends DefaultListSelectionModel {
   protected JComponent boss;
    public MyGreatListSelectionModel(JComponent c) {
        boss = c;
    @Override protected void fireValueChanged(int firstIndex, int lastIndex, boolean isAdjusting)
        Object[] listeners = listenerList.getListenerList();
        ListSelectionEvent e = null;
        for (int i = listeners.length - 2; i >= 0; i -= 2) {
            if (listeners[i] == ListSelectionListener.class) {
                if (e == null) {
                    // Only changed 'this' to 'boss'
                    e = new ListSelectionEvent(boss, firstIndex, lastIndex, isAdjusting);
                ((ListSelectionListener)listeners[i+1]).valueChanged(e);
}This should work, but if there already exists some mechanism, such extension is just slowing app down.

Thanks for your help.
However I could not get the result. I am using following code:
public void myaction(ActionEvent event)
FacesContext context = FacesContext.getCurrentInstance();
UIViewRoot view = context.getViewRoot();
UIComponent UI = view.findComponent("tab");
if(UI == null)     
     System.out.println("UI Not Found ");
else
     System.out.println("Get Current FecesContext");
There is an Component having id "tab" is available on JSF page but I am getting "UI not Found" every time. Is there somthing wrong...Please suggest.

Similar Messages

  • PortalRuntimeException in Business Object document iview No portal component associated with the following context

    Hi all,
    We are stumped with a problem in our QA Enterprise Portal (7.3.1 Sp7) that throws a portal runtime error when we preview a Business Objects document iview.  The Business Objects Server versions are 4.0 SP5 and/or 4.1 SP3.
    The error is caught in the the defaultTrace file, /usr/sap/QNW/J00/j2ee/cluster/server0/log
    [EXCEPTION]
    com.sapportals.portal.prt.runtime.PortalRuntimeException: There is no portal component associated with the following context:
    pcd:portal_content/com.summit.SES_BI/com.summit.iviews/Daily_Margin
    at com.sap.portal.prt.component.PortalComponentContext.<init>(PortalComponentContext.java:93)
    Here is what we have tried
    * Confirmed the iviews exist in the PCD, by browsing to the content folders and right lick, preview on the iview.
    * Our PRD and DEV systems work correctly and are on same versions of EP Runtime and java. 7.3.1.7.0.201..
    * Occurs with all Businessobjects iviews from the QA portal and all doc types, webis, dashboards. Tried creating new iview.
    * Reapplied the com.sap.businessobjects.iviews.templates.epa to the Portal from t he BI 4.1 SP3 distribution
    * Deleted and recreated the BI portal system connector using the SAP BOBJ system template set path to http://bi-qas:8080/BOE
    * Set the embed key value in the BI system connector property and in the custom global.properties file, restarted tomcat and SIA services
    * Set permissions for everyone end user on the content folders and the BI system connector
    * Confirmed Single sign on configured correctly between BI and Portal
    * Confirmed that the QA BI server is configured correctly by directing the working DEV Portal to the QA BI server.
    * Performed actions in note 1709737
    We are certainly stuck and the defaultTrace file is not very informative.  Any suggestions are greatly appreciated
    Lee Lewis

    This is resolve with note 1615838  - SAP Netweaver Enterprise Portal 7.3 iView creation with BI 4.0 results in exceptions.
    The note includes a file portalapp.xml that need to be inserted into com.sap.businessobjects.iviews.par that is included in the BI server distribution.
    Then deploy the ear file.....
    Odd thing is that the note mentions 4.0 and we are on 4.1 SP3...
    Environment
    SAP BusinessObjects BI Platform 4.0 SP02 Patch 4 or lower
    SAP Netweaver Enterprise Portal 7.3
    Lee Lewis

  • Is it possible to change artwork associated with albums/tracks?

    Hi, Does anyone know if it's possible to delete and/or change the artwork associated with albums or tracks please?

    right-click (or ctrl-click) on one file in iTunes and get info. go to the artwork tab and click once on the existing artwork, then hit delete to remove it. paste new artwork into the box or click on add and navigate to the image on your hard drive. you can also drag artwork directly from your web browser into the box.
    highlight multiple files in iTunes, then right-click on the selection and get info. the artwork box for multiple items will be empty. put a check into the little box next to the artwork box and hit ok to delete existing artwork. or, paste the new artwork into the artwork box and hit ok to change the artwork. you can also drag artwork directly from your web browser into the box.

  • Getting hostname associated with an interface assigned its address by DHCP

    I'm trying to get my VirtualBox install of Solaris 11 Express to assign the hostname to the DHCP acquired address for its Ethernet I/F. All attempts to find a solution has covered earlier versions of Solaris and the only reference I could find was in the Post-installation notes which directs you to use netcfg and/or netadm. Neither of these commands exist on my installed system. I need the address assigned by DHCP to be associated with the hostname as defined by /etc/nodename as I want to use an RMI server on this system.
    Any suggestions gratefully received.
    George Nelson

    Frop
    Ok what is the point to write something uou have alreadt written above?
    I said "What to do to fix it you decide", because your advice to disable IPv6 will bring to him additional problems like this preventing creation of homegroup if IPv6 is disabled and maybe some other problems!
    This is not competition, but to help means to resolve the problem, but not to solve it somehow by creating a lot of other problems

  • Possible to Get Database backup with java program

    Hello
    Is it possible to Get or Create Database Backup on runtime with java program using some sql statements
    How could i do that
    '

    Cross posted and multi-posted.
    Hey jackass why don't you look where I already answered this question.
    http://forum.java.sun.com/thread.jspa?threadID=654902&messageID=3849575

  • Possibility of getting serial report with sales invoice details

    Hi All,
    We are Telco company and there is a requirement to view the serial numbers issued to a customer along with the invoice number, invoice date and invoice value.
    Is this possible? If yes, please let me know the tables which can be used in SQVI.
    Thanks,
    Savindi

    Hi,
    Refer the below link it may help you.......
    Re: Invoice details related to Serial Numbers

  • Is it possible to get a T61 with discrete Graphic card and NO OS?

    Hi
    Thank you for reading my post.
    I am looking to know whether I can get aT61 with discrete Graphic card and NO OS?
    I dont like to pay for the OS as I will install Ubuntu.
    Thanks 
    Solved!
    Go to Solution.

    No you can't, unless you're a corporate customer ordering (at least) several hundred pieces.
    Cheers,
    George
    In daily use: R60F, R500F, T61, T410
    Collecting dust: T60
    Enjoying retirement: A31p, T42p,
    Non-ThinkPads: Panasonic CF-31 & CF-52, HP 8760W
    Starting Thursday, 08/14/2014 I'll be away from the forums until further notice. Please do NOT send private messages since I won't be able to read them. Thank you.

  • Is it at all possible to get mountain lion with an older MacBook?

    I have a mid-2007 MacBook with upgraded RAM to 4GB and sufficient hard disk space. 
    The App store won't even let me download Mountain Lion (even though my computer meets the basic specs), and Lion isn't avail. either.  WHat other specs does my computer not meet to upgrade to Mountain Lion??   Will I forever be stuck with SnowLeopard?  It is really unfair that Apple won't even continue making software patches for people with older machines who can't get the latest OSx upgrade.  Not every Apple owner can afford to by a new notebook every 2 years.  Stop being so greedy Apple.....

    There is a min requirement on the machine itself. 
    See this link:
    http://www.tuaw.com/2012/02/16/mountain-lion-drops-support-for-several-older-mac -models/
    If you really want to upgrade away from Snow Leopard, you can call Apple to buy the Lion usb.
    In my opinion, the ONLY reason that I upgraded to Lion is the new File Vault (I have a Macbook 2008).  If you don't use file vault I don't see a reason to upgrade to Lion because you are not able to use most of the feature that it offers anyway, such Air Drop or Improved mouse touch detection.
    I don't think for my Macbook 2008 ( or your Macbook 2007), Lion is that great of an upgrade : )

  • Possible to get Double Play with 105Mbps Internet?

    Hello, due to the ridiculous data caps being enforced by Comcast, I am already 90% to my data cap 11 days into the month. I am willing to upgrade to the 105 internet to get double the cap, but based on the plans listed, the only way to do this is to switch from my 99.99/mo Double Play package to a 159/mo Triple Play package.
    This is ridiculous. I am willing to spend 10-20 more a month for the faster speed, but not $60 more for service I don't even need. I'm sure by this point I've been flagged as a "problem customer" because I have had issue after issue with Comcast since my installation less than a month ago. To find out now that I will be spending huge overage fees in addition to what I'm already paying is just about the last straw...

    jrlepagejr wrote: ... I was told by an Indian chat representative that the 105mbps internet included 600GB of data per month. Is that even true? ...If you are not in the Tucson area, no. If you are in the Tucson area, maybe. See http://customer.xfinity.com/help-and-support/internet/data-usage-trials-what-are-the-different-plans-launching

  • Is it actually possible to get in touch with Apple directly?

    Hi, does anyone know if it is possible to ask Apple a question directly either over chat or email? The reason I ask is I am based in the UAE and called Apple here and they refused to help me as I didnt buy my phone from the online store and told me to contact the shop I bought it from.
    The trouble is this is NOT a problem with the phone its iCloud or it happened after upgrading to iOS 6, but some contacts which were on my phone are no longer displaying in 'My Contacts' however when I type the number in manually they appear. They are also listed in my Whatsapp contacts so I know they are no my phone.
    I have also tried checking for them on iCloud.com however they are not there either. I have also gone to contacts Groups to make sure it says display all contacts which it does.
    The biggest question here is I had this problem on my 3Gs and have just got the iPhone 5 and the same issue has happened here?!?!

    Still no email address, Ive been through the various options so many times but no one to contact and I cant call the guys in the UAE as they wont speak to me.

  • Com.sapportals.portal.prt.runtime.PortalRuntimeException: There is no portal component associated with the following context: pcd:portal_content/

    Hello experts,
    Recently we upgraded support pack of ECC system.After upgrade few user reported error message in Portal system.I am attaching screen shot for reference.Since this problem has been reported only by few users, I doubt if it is related to authorization.Please guide me.
    Thanks
    Aditya

    Hi Aditya,
    Please go through the below thread for the similar issue:
    SAP EP 6.0 to 7.3
    BR,
    Anurag

  • How to get component item list assembly Item

    Hi,
    I am trying to get component list with assembly item.
    I have assembly item number and serial number and i want to see all components with serial number for this assembly.
    Can any one tell me query for this?
    Thanks
    Ravi

    Hello,
    You get the value as for any other Forms item:
    :value := :block.list_tem ;Francois

  • Status associated with WBS element

    Hi,
    How can we get status associated with WBS element.
    thanks

    Hi,
    Couldn't find function module to get status associated with WBS element. I want the status description i.e if we run transaction code CN43.  the status column value 'TECO' then what's the description

  • Webi reports and objects associated with uiverses

    Hi,
    I want to know the list all universes associated with wei reports and their objects (database field) using query builder.
    I am using select * from ci_infoobjects where si_kind='Webi'. I could able to get the universe associated with webi report in fielf si_webi_doc_properties.
    1) How can I get only UnvName from XML
    2) How to get objects associated with a webi reports

    Hi Jaya,
    Have you also tried finding the report within CMC and then right clicking and selecting relationships? It should show you all Universes associated with your report. If you meant all reports related to a Universe, you can do the same for the Universe.
    Thanks

  • Finding Plants\Storage locations associated with the Routes

    Hi,
    I need to find all possible Plants/Storage Locations associated with the Route in hand.(These routes can be found in TVRAB table).Is there any mapping done in SAP between Routes and Plants or Routes and Departure Points ?
    If anyone has any inputs regarding this, it will be really helpful.

    Hi,
    To determine the route we need to know the Plant and the Shipping point or connection point/port.
    I think we can find the routes in table TVRO or VBLK.
    and for route descirption we go for the TVROT
    First check the tables for the Plant and shipping point then we can link to the route.
    Pls check this link
    http://help.sap.com/saphelp_47x200/helpdata/en/dd/560dee545a11d1a7020000e829fd11/frameset.htm
    http://help.sap.com/erp2005_ehp_03/helpdata/EN/17/c0b758903111d2b42f006094b9b9a0/content.htm
    Regards
    Lekha

Maybe you are looking for

  • How do I install new Adobe flash on my notebook?

    I have tried several times to download the new Adobe in order to play games on my Mac but it downloads says its complete and for me to restart safari.  Then does not work.  Is Adobe just not compatable with Mac?

  • Fade effect causes audio popping

    Hello, I have had a recent issue with iMovie which is only getting worse. Whenever I use the video effect of either fade in or fade out, there is a popping sound which get written into the audio track. I have tried various fixes but nothing seems to

  • How to add attachments to Webdynpro Application?

    Hi All, I have a requirement wherein I need to add supporting documents to a Webdynpro application online. The attachments can be of any type and any number of attachments can be added. If any of you had worked in such a kind of requirement please gi

  • Icloud Date Format wrong...

    iCloud date format preferences do not work. Day Month Year is an option but it doesn't reflect in places like the calander.

  • Function help :

    I need a function that has to find out if a pk already has been assigned in another table as an foreign key. I've written this: function check ( id1 in number return varchar2 is cursor c ( b number ) is select id from a, b where a.pk1= b and b.fk_id