?
Solved

Create sub column in JTable

Posted on 2011-02-20
7
Medium Priority
?
1,187 Views
Last Modified: 2013-11-23
I am using Jtable. I want to set coloumn heading in the format like, if table contains column 'colmn1' then i want 2 sub columns in main coloumn say 'colmn1.1' and 'column1.2'. How should i do it? I am using following code,
private javax.swing.table.DefaultTableModel tm = new javax.swing.table.DefaultTableModel(rows,coloum);
tblsearch.setModel(tm);
0
Comment
Question by:Aurii
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 
LVL 4

Expert Comment

by:aaver
ID: 34937612
I'm not sure I understand. Do you want one heading with name "column1" and two sub headings below, named "column1.1" and "column1.2"? In other words, do you want the heading "column1" to span two columns?
0
 
LVL 4

Accepted Solution

by:
aaver earned 2000 total points
ID: 34937620
0
 

Author Comment

by:Aurii
ID: 34940029
I want one heading with name 'column1' and 2 sub headings below, named 'column1.1' and 'column1.2'
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 4

Expert Comment

by:aaver
ID: 34940515
Ok, then the second link should be interesting: http://www.codeguru.com/java/articles/124.shtml
0
 
LVL 4

Expert Comment

by:aaver
ID: 34940686
The links looked promising at first, but now I'm not so sure any more. I will try to find out a better way.
Sorry for any inconvenience.
0
 

Author Comment

by:Aurii
ID: 35108157
These solutions not worked. Please suggest me some useful solution.
0
 
LVL 37

Expert Comment

by:zzynx
ID: 35422217
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In our object-oriented world the class is a minimal unit, a brick for constructing our applications. It is an abstraction and we know well how to use it. In well-designed software we are not usually interested in knowing how objects look in memory. …
Update (December 2011): Since this article was published, the things have changed for good for Android native developers. The Sequoyah Project (http://www.eclipse.org/sequoyah/) automates most of the tasks discussed in this article. You can even fin…
The viewer will learn how to use NetBeans IDE 8.0 for Windows to connect to a MySQL database. Open Services Panel: Create a new connection using New Connection Wizard: Create a test database called eetutorial: Create a new test tabel called ee…
The viewer will learn how to use and create keystrokes in Netbeans IDE 8.0 for Windows.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question