ListSpinner
Hello,
I am unable to find any samples with spinners for NetBeans. I
have successfully copied Java samples to NetBeans and they
compile and run OK but when I try to incorporate the code into
my own design in NetBeans I cannot get the spinners to work.
I now made the simplest project possible with a JField, a
JSpinner and a JButton.
I want the spinner to display a list of three words, "first",
"second" and "third" but all I get when I run the project is
stuck on the word "first" in the field and the spinner just
cycles through numbers. I want the words to appear in the
spinner window, not the field. The field is there just to test
what is happening/not happening.
public void createEntryFields () {
String[] stateStrings = getStateStrings();
SpinnerListModel listModel = new
SpinnerListModel(stateStrings);
JSpinner stateSpinner = new JSpinner(new
SpinnerListModel(stateStrings));

