greetings, how can i get value from JTable and set it to textfield. I have to classes, one for JTable class and other for Textfield class, how can i get the value when i select value from JTable class and put it on textfield which is another class..... i really need this, please help me..... thanks..
Welcome to the JavaRanch! We don't have many rules around the ranch, but we do have a policy on displayed names... Please adjust your displayed name to meet the JavaRanch Naming Policy. User names cannot be obviously fake and must consist of a first name and a last name.
You'll have to use a Listener to listen for events in the table, and in response to those events, set the text of the textfield.
Joined: May 17, 2007
Thanks for the reply.....but I have something to add, I want my selected value from the table will be display to another class. For example, class Table and Class Main....when i click button Find in the Main class the table from Table Class will be display and when I select value from the table and click the button Select the selected value will display to the Textfield of Main Class. How can i get it. Many thanks and I hope you could help me again.......