• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Paul Clapham
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Roland Mueller
  • Piet Souris
Bartenders:

Mouselistner not working for a table object

 
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I have a JTable object called VTable present in the swing package. For this JTable, none of the listeners gets executed.

The above mouseListener doesnt get executed.

Or do we have to create a view only.

[ EJFH: Everyone thinks their post is urgent, yours no more so than others. ]
[ April 08, 2005: Message edited by: Ernest Friedman-Hill ]
 
Greenhorn
Posts: 29
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
You need to add Mouselistener to the table Header.

Try using the below code:

VTable m_table = new VTable(rowData,colNames,false); m_table.getTableHeader().addMouseListener(new java.awt.event.MouseListener(){ public void mouseClicked(MouseEvent e) { System.out.println("TEST!!!"); }

Thanks,
 
reply
    Bookmark Topic Watch Topic
  • New Topic