| Author |
Display data from database into JComboBox
|
chiatai goh
Greenhorn
Joined: Mar 19, 2005
Posts: 3
|
|
Hi programmers! How can i display the datas from database into JComboBox? This are the codes for actionPerformed: public void actionPerformed (ActionEvent e){ JButton clickedButton = (JButton) e.getSource(); if(clickedButton == retrieving) retrievingClicked(); JComboBox typeList = (JComboBox)e.getSource(); String typeStrings = (String)typeList.getSelectedItem(); //updateLabel(typeStrings); typeList.addItem(typeStrings); } What's the next step? [ March 19, 2005: Message edited by: chiatai goh ] [ March 19, 2005: Message edited by: chiatai goh ]
|
 |
Jeanne Boyarsky
internet detective
Marshal
Joined: May 26, 2003
Posts: 26144
|
|
Chiatai, Welcome to JavaRanch! Take a look at Sun's JDBC tutorial for the basics of JDBC. Feel free to post in this thread when you have a more specific question.
|
[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
|
 |
 |
|
|
subject: Display data from database into JComboBox
|
|
|