Questions tagged [comboboxmodel]

48 questions
0
votes
2 answers

JComboBox populated by string array(using for loop) not appearing

I am trying to populate my JComboBox with numbers 25 to 50 and this is what I've done, --at the variable declarations-- String[] val = new String[25]; JComboBox box1 = new JComboBox(); --and in the "main"-- for(int i=0; i==val.length; i++){ …
Malice Sloth
  • 45
  • 3
  • 12
0
votes
2 answers

JComboBox item listener

I have two combo boxes. The first contains some operator (+ , - ,* ,/) and the second one contains some value from 0 to 10. When user select (/) in first combo box I want the second one to show a value from 2 to 10 instead of 0 to 10. I've tried…
lina
  • 75
  • 2
  • 4
  • 10
-4
votes
1 answer

combobox error at compile time

I want the combobox to store the name from database at runtime,so i creted a list but combobox is displaying an error... List s = new ArrayList(); { try { …
Paras Dhawan
  • 364
  • 8
  • 23
1 2 3
4