First, i'm new at Java-programming and my native lang is not english, but still i hope to get some help from you all. What I try to do is a simple java-interface with a jComboBox and a jList. I want to poplate to jComboBox with Object-names and when the user select one of the names get the object-id which i will use to populate the jList. It's probably simple but i have bin stuck with this problem all day.
private void loadComboBox() {
biz.Object object = new biz.Object();
try {
ArrayList<biz.Object> arrayOfObjects= object.getAllObjects();// ArrayList of objects
for (biz.Object o:arrayOfObjects)
{
if (o != null)
cbm.addElement(o); //`toString-method
}
cb.setModel(cbm); //JComboBox