🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.swing
Article #12063

creating JTable row dynamically

#12063
From: ahmedsajjad
Date: Tue, 02 Mar 1999 00:00
20 lines
1336 bytes
Hello,

I have an applet with three text fields (JTextField) and 2 buttons (JButton).
There is also a table (JTable) within this applet. The buttons are used to
add and delete rows from the table dynamically. (All components within the
applet are Swing components).

The table has three columns, Col1, Col2, and Col3. Based on the user input,
the rows are added to the table upon clicking Add Button. A row could be
deleted using Delete Button.

I would like to know how to add/delete rows to a table (JTable) dynamically.
Any example of this would be appreciated.

Thanks,

Ahmed Sajjad

-----------== Posted via Deja News, The Discussion Network ==----------
http://www.dejanews.com/       Search, Read, Discuss, or Start Your Own    
Technical Details
Message-ID: <7bhh2d$dff$1@nnrp1.dejanews.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 111d45,3545eba27b0eb676,start
X-Google-Attributes: gid111d45,public
From: ahmedsajjad@hotmail.com
Subject: creating JTable row dynamically
Date: 1999/03/02
Message-ID: <7bhh2d$dff$1@nnrp1.dejanews.com>
X-Deja-AN: 450459379
X-Http-Proxy: 1.0 x9.dejanews.com:80 (Squid/1.1.22) for client 139.144.1.208
Organization: Deja News - The Leader in Internet Discussion
X-Article-Creation-Date: Tue Mar 02 20:18:31 1999 GMT
Newsgroups: borland.public.jbuilder.java.swing
X-Http-User-Agent: Mozilla/4.5 [en] (WinNT; I)