Change the line:double doubleValue =doubleValue(tempValue);To:double doubleValue =tempValue.doubleValue();ThedoubleValue() method is an instance method which you use onyour tempValue which is an instance of the Doubleclass.