By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
444,225 Members | 2,170 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 444,225 IT Pros & Developers. It's quick & easy.

Models in Swing.

dmjpro
100+
P: 2,476
Now a days I am working in Swing.
So guys please help me to do my project.
Actually the time is short to read out those things.

What i have a confusion ..that .....

Expand|Select|Wrap|Line Numbers
  1. DefaultTableModel tab_model = new DefaultModel(...);
  2. JTable tab = new JTable(tab_model);
  3. //Now if I change to tab_model then automatically updation notification goes to tab??
  4.  
Debasis Jana.
Mar 30 '08 #1
Share this Question
Share on Google+
6 Replies


Expert 10K+
P: 11,448
Now a days I am working in Swing.
So guys please help me to do my project.
Actually the time is short to read out those things.

What i have a confusion ..that .....

Expand|Select|Wrap|Line Numbers
  1. DefaultTableModel tab_model = new DefaultModel(...);
  2. JTable tab = new JTable(tab_model);
  3. //Now if I change to tab_model then automatically updation notification goes to tab??
  4.  
Debasis Jana.
Why don't you just try it if you don't want to read? Are you planning to ask every
little Swing issue here just because you don't want to read the API documentation?
It'll cost you a lot more time to produce anything sensible then.

btw, not supplying a TableModel makes the JTable produce its own DefaultTableModel.

kind regards,

Jos
Mar 30 '08 #2

dmjpro
100+
P: 2,476
Why don't you just try it if you don't want to read? Are you planning to ask every
little Swing issue here just because you don't want to read the API documentation?
It'll cost you a lot more time to produce anything sensible then.

btw, not supplying a TableModel makes the JTable produce its own DefaultTableModel.

kind regards,

Jos

What I guessed that's right ...if i change to Model then it reflects to that corresponding table.

Debasis Jana
Mar 30 '08 #3

10K+
P: 13,264
What I guessed that's right ...if i change to Model then it reflects to that corresponding table.

Debasis Jana
Don't play guessing games with the compiler. Just refer to the API docs.
Mar 31 '08 #4

Expert 10K+
P: 11,448
Don't play guessing games with the compiler. Just refer to the API docs.
I normally fall asleep with my nose on the keyboard. When I wake up I expect to
see the most beautiful code. If there isn't any I fall asleep and try again :-)

kind regards,

Jos
Mar 31 '08 #5

SammyB
Expert 100+
P: 807
> fall asleep with my nose on the keyboard. When I wake up I expect to
see the most beautiful code. If there isn't any I fall asleep and try again :-)

This works just like evolution -- you just need to try for a longer period of time. ;o)>>> Sam
Mar 31 '08 #6

Expert 10K+
P: 11,448
> fall asleep with my nose on the keyboard. When I wake up I expect to
see the most beautiful code. If there isn't any I fall asleep and try again :-)

This works just like evolution -- you just need to try for a longer period of time. ;o)>>> Sam
I can't do that, I mean I have to go to bed at night, I need my sleep too you know!

kind regards,

Jos ;-)
Mar 31 '08 #7

Post your reply

Sign in to post your reply or Sign up for a free account.