Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Basic Calculator Issue
#6
Alright, I see the problem.

What you're going to want to do is change this line:
Code:
String answer = df.format(res);

To this:
Code:
String answer = df.format(product);

This is because what you were trying to do was format the TextField as a String. However, you can't make that conversion. So, we need to format the answer (product) as a String, and then display it in the textfield.
My Blog | My Setup | My Videos | Have a wonderful day.


Messages In This Thread
Basic Calculator Issue - by Vinwarez - 07-10-2012, 04:59 AM
Re: Basic Calculator Issue - by Vinwarez - 07-10-2012, 01:48 PM
Re: Basic Calculator Issue - by Vinwarez - 07-11-2012, 05:31 AM
Re: Basic Calculator Issue - by brandonio21_phpbb3_import2 - 07-11-2012, 12:31 PM
Re: Basic Calculator Issue - by Vinwarez - 07-11-2012, 11:45 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)