Article View: borland.public.jbuilder.java.api
Article #2106Special format for JTable column Header
From: Laurent Souriau
Date: Fri, 15 Jun 2001 12:37
Date: Fri, 15 Jun 2001 12:37
35 lines
2418 bytes
2418 bytes
Hi,
I currently have the following problem :
I have a Jtable with a DefaultTableModel(),
I pass a list of values and of columnnames by :
myModel = new defaultTableModel(data, columnNames);
table.setModel(myModel);
Then the columnames content is :
"Date" "VLR / SFR" "VLR / ITINERIS" "VLR / MOBISTAR"
It appears like above in my column headers.
I would like the headers to appear like this :
Date VLR VLR VLR
SFR ITINERIS MOBISTAR
I tried to fill the columnnames content with :
"Date" "VLR \n SFR" "VLR \n ITINERIS" "VLR \n MOBISTAR"
But it doesn't produce what i want ( i have a carriage return character
instead
of appearing in 2 lines.
any help would be greatly appreciated.
Laurent
e-mail : lsouriau@club-internet.fr
Technical Details
Message-ID:
<9gcvcu$8kp$1@s1.read.news.oleane.net>Path:
arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!193.251.151.101!opentransit.net!proxad.net!oleane.net!oleane!nnrp.oleane.net!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 1089d0,967d0259ba18d10e,start X-Google-Attributes: gid1089d0,public X-Google-Thread: 10568c,967d0259ba18d10e,start X-Google-Attributes: gid10568c,public X-Google-Thread: 10a146,967d0259ba18d10e,start X-Google-Attributes: gid10a146,public X-Google-Thread: f631b,967d0259ba18d10e,start X-Google-Attributes: gidf631b,public X-Google-Thread: 113ae9,967d0259ba18d10e,start X-Google-Attributes: gid113ae9,public X-Google-Thread: f74b3,967d0259ba18d10e,start X-Google-Attributes: gidf74b3,public X-Google-ArrivalTime: 2001-06-15 05:35:03 PST Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!news.tele.dk!193.251.151.101!opentransit.net!proxad.net!oleane.net!oleane!nnrp.oleane.net!not-for-mail From: "Laurent Souriau" <lsouriau@club-internet.fr> Newsgroups: borland.public.jbuilder.java.api,borland.public.jbuilder.java.language,comp.lang.java.help,comp.lang.java.programmer,de.comp.lang.java,fr.comp.lang.java Subject: Special format for JTable column Header Date: Fri, 15 Jun 2001 14:37:53 +0200 Organization: Guest of France Telecom Oleane's newsreading service Lines: 42 Message-ID: <9gcvcu$8kp$1@s1.read.news.oleane.net> NNTP-Posting-Host: aqsacom.rain.fr X-Trace: s1.read.news.oleane.net 992608479 8857 195.6.24.78 (15 Jun 2001 12:34:39 GMT) X-Complaints-To: abuse@oleane.net NNTP-Posting-Date: Fri, 15 Jun 2001 12:34:39 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400