Search
Search titles only
By:
Search titles only
By:
Log in
Register
Search
Search titles only
By:
Search titles only
By:
Menu
Install the app
Install
Forums
New posts
All threads
Latest threads
New posts
Trending threads
Trending
Search forums
What's new
New posts
New ads
New profile posts
Latest activity
Free Ads
Latest reviews
Search ads
Members
Current visitors
New profile posts
Search profile posts
Contact us
Latest ads
එක පැකේජ් එකයි මාසෙටම Unlimited Internet. තාමත් DATA CARD දාන්න සල්ලි වියදම් කරනවද? අඩුම මිලට අපෙන්.
sayuru bandara
Updated:
Tuesday at 12:30 PM
Ad icon
ඉන්ටර්නෙට් එකෙන් හරියටම සල්ලි හොයන්න සහ Success වෙන්න කැමතිද? 🚀 (E-Money & Success Stories)
siri sumana
Updated:
Saturday at 11:44 PM
Gemini AI PRO 18 months Offer
Hawaka
Updated:
May 27, 2026
Ad icon
koko account
DasunEranga
Updated:
May 27, 2026
Ad icon
koko account
DasunEranga
Updated:
May 27, 2026
Electronics
Vehicles
Property
Search
Reply to thread
Forums
General
ElaKiri Help
java help needed
Get the App
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Message
<blockquote data-quote="amilabanuka" data-source="post: 7290863" data-attributes="member: 5836"><p>front end kiwe ui handling part ekata n back end kiwe ube db handling part eka. UI gana nam wadiyama danne na mama. back end eka gana nam awulak na goda dala denna puluwna.</p><p></p><p>thawa ekak. uba jTable ekata nikammane data danne. ohoma danne nathuwa TableModel ekak use karanna.</p><p></p><p>[CODE]</p><p>Object rowData[][] = {{"Row1-Column1", "Row1-Column2", "Row1-Column3"},</p><p> {"Row2-Column1", "Row2-Column2", "Row2-Column3"}};</p><p> Object columnNames[] = {"Column One", "Column Two", "Column Three"};</p><p> </p><p> TableModel model = new DefaultTableModel(rowData, columnNames);</p><p> tblData.setModel(model);</p><p>[/CODE]</p><p></p><p>in this way u can simply update the data in the table. you just have to update the model and set it. rather than creating the jTable when you want to feed data to the table this is the standered way.</p><p></p><p>if you want, if the user is supposed to select data from the table you can use</p><p></p><p>[CODE] </p><p>int selectedIndex = tblData.getSelectionModel().getMinSelectionIndex();</p><p>[/CODE]</p></blockquote><p></p>
[QUOTE="amilabanuka, post: 7290863, member: 5836"] front end kiwe ui handling part ekata n back end kiwe ube db handling part eka. UI gana nam wadiyama danne na mama. back end eka gana nam awulak na goda dala denna puluwna. thawa ekak. uba jTable ekata nikammane data danne. ohoma danne nathuwa TableModel ekak use karanna. [CODE] Object rowData[][] = {{"Row1-Column1", "Row1-Column2", "Row1-Column3"}, {"Row2-Column1", "Row2-Column2", "Row2-Column3"}}; Object columnNames[] = {"Column One", "Column Two", "Column Three"}; TableModel model = new DefaultTableModel(rowData, columnNames); tblData.setModel(model); [/CODE] in this way u can simply update the data in the table. you just have to update the model and set it. rather than creating the jTable when you want to feed data to the table this is the standered way. if you want, if the user is supposed to select data from the table you can use [CODE] int selectedIndex = tblData.getSelectionModel().getMinSelectionIndex(); [/CODE] [/QUOTE]
Insert quotes…
Verification
Asuwa dahayen wadi kalama keeyada?
Post reply
Top
Bottom