>Vector vec = new Vector();
>DefaultTableModel data = new DefaultTableModel();
>JTable table = new JTable(data);
>
>but there is nothing in JTable on my JFrame (after I read file with
>data and wanted to insert it in JTable).
See if you can find a cheap Swing textbook that has some sample JTable
code or some sample code on the net that uses the classes you need.
What you do is create a new class that extends DefaultTableModel and
hence implements TableModel. In that code you write addRow etc. to
insert data into your Vector.

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.
cernesimon@gmail.com - 20 Oct 2005 19:50 GMT
I add data into vector with .addElement method then I add this vector
with .addRow to DefaultTableModel but I doesn't show in JTable I have
on my JFrame.
What to do, have any suggestion
Simon
Roedy Green - 21 Oct 2005 04:02 GMT
>I add data into vector with .addElement method then I add this vector
>with .addRow to DefaultTableModel but I doesn't show in JTable I have
>on my JFrame.
you are missing your fire methods that tell Swing what you changed
that needs repainting.
see http://mindprod.com/jgloss/jtree.html
and look at the tutorials.

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.