One line 83 add code to call the


Write an application that perfoms various temperature conversions. The application should be capable of performing two types of conversions: degrees Fahrenheit to degrees Celsius and degrees Celsius to degrees Fahrenheit. Your input should look like Fig 13.24

c. on line 57, add code to call the fahrenheitJTextFieldActionPerformed method. Pass to the method the ActionEvent object event as the argument.

d. Starting after the createUserInterface method, on line 97, declare the fahrenheitJTextFieldActionPerformed method. This method should get the value from fahrenheitJTextfFeld, convert it to Celsius and display it in celsiusJTextField. DecimalFormat temperature should be used to format the output. To convert degrees Fahrenheit to degrees Celsius, use this formula:

degreesCelsius = ( degreesFahrenheit - 32.0 ) * 5.0 / 9.0;

e. One line 83, add code to call the celsiusJTextFieldActionPerformed method. Pass to the method the ActionEvent object event as the argument.

f. Starting after the fahrenheitJTextFieldActionPerformed method, on line 115, declare the celsiusJTextFieldActionPerformed method. This method should get the value from celsiusJTextfFeld, convert it to Fahrenheit and display it in celsiusJTextField. DecimalFormat temperature should be used to format the output. To convert degrees Celsius to degrees Fahrenheit, use this formula:

degeesFahrenheit = 9.0 /5.0 * degrees Celsius + 32.0;

 

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: One line 83 add code to call the
Reference No:- TGS0661188

Expected delivery within 24 Hours