jspinner getting data

Hi,

I have a jspinner i try to get from it a value .getValue() this value is an object , how can i make an integer from it. the spinner is a number spinner from 0 to 999; I ned to get the value of the spinner and multiply it with a double

example

price=price*spinnerValue;

Can u help me?

[318 byte] By [Tottigola] at [2007-11-27 5:30:16]
# 1
Well, since the object is probably an Integer, or at least a Number, you can do this:int v = ((Number)spinner.getValue()).intValue();
bsampieria at 2007-7-12 14:54:11 > top of Java-index,Desktop,Core GUI APIs...