mport java.util.ArrayList;
import javax.swing.JComboBox;
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
/**
*
* @author aluno
*/
public class clsCliente {
private ArrayList<String> Nome = new ArrayList<String>();
private ArrayList<String> telefone= new ArrayList<String>();
private ArrayList<String> placa= new ArrayList<String>();
private ArrayList<String> modelo= new ArrayList<String>();
private ArrayList<String> tp_veiculo= new ArrayList<String>();
private ArrayList<String> marca= new ArrayList<String>();
private ArrayList<String> ano= new ArrayList<String>();
private ArrayList<String> dtCadastro = new ArrayList<String>();
public void encheComboBox(JComboBox cmb)
{
String str;
for (int i = 0; i < this.Nome.size(); i++)
{
if("".equals(this.Nome.get(i)))
{
str = "Nenhum cliente cadastrado.";
cmb.add(str, cmb);
break;
}
else
{
str = (String) this.Nome.get(i).toString();
cmb.add(str, cmb);
}
}
}
O problema que o metodo da encheComboBox não está preenchendo, alguém tem alguma dica de como eu possa está resolvendo isso?