wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes Is JTable dynamic (-urgent-) ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Is JTable dynamic (-urgent-) ?" Watch "Is JTable dynamic (-urgent-) ?" New topic

Is JTable dynamic (-urgent-) ?

Smilidon Sapiens
Ranch Hand

Joined: Nov 02, 2000
Posts: 66
I want to insert some data from a txt-file in a table. If I use the object[][] I must know what data I have to insert there. How can I insert data to the table when I don't know how many cols I have?
Please help, thanks!
[This message has been edited by Brain Tenner (edited December 14, 2001).]
sean mclaughlin

Joined: Nov 29, 2001
Posts: 8
do you mean how many rows you have? if you do simply call the getRowCount() function of jtable to find out how many r already there. Jtable is dynamic and all u have to do is add an item using the addElement method from the default table model.
sean's software tips

sean's software tips
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
subject: Is JTable dynamic (-urgent-) ?
Similar Threads
inert data into hbase from opentsdb?
Insert more than one row in database.
mysql help
update a JTable