File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Swing / AWT / SWT and the fly likes Get ID value on database from JCombo Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Get ID value on database from JCombo" Watch "Get ID value on database from JCombo" New topic

Get ID value on database from JCombo

Tobias Leon

Joined: Apr 17, 2012
Posts: 22

Hi there !!!

I have a JCombo with names, each name has a ID in my database, I need to get that ID each time I pick a item from my JCombo.

I try something like this:

But it does not work, something about not cast CPerson from String.

Thanks !!!

Murphy's Law
Darryl Burke

Joined: May 03, 2008
Posts: 4523

To get better help sooner, post a SSCCE (Short, Self Contained, Compilable and Executable) example that demonstrates the problem.

luck, db
There are no new questions, but there may be new answers.
I agree. Here's the link:
subject: Get ID value on database from JCombo
Similar Threads
JCOMBO Box traversal problem
JCombo Box Problem
JCombo model?
JCombo Box And JTable
JCombo box inside a JTable Cell?