Using Javafx Use Formula Calculate Appropriate Bmi Values Notice Even Input Pounds Inches Q37020456

Using JavaFx. Use the formula to calculate the appropriate BMIvalues. Notice that even when the input is pounds and inches, theoutput is kg/m^2 do not forhget to multiply by 703 ifthe U.S. radio button is selected. This result should appear whenthe Calculate button is pressed.

Use these Formulas:

Formula: weight(kg)/ [height(m)]2

Formula: 703xweight(ibs)/height(in)]2

.Only modify the change Unit and Calculated Result.

BMIController.java file below:

package bmi;

import javafx.event.ActionEvent;
import javafx.fxml.FXML;
import javafx.scene.control.Button;
import javafx.scene.control.Label;
import javafx.scene.control.RadioButton;
import javafx.scene.control.TextField;

public class BMIController {
   @FXML
    private Button calculate;

    @FXML
    private Label heightLBL;
    @FXML
    private Label result;
    @FXML
    private Label weightLBL;

    @FXML
    private RadioButton us;
    @FXML
    private RadioButton metric;

    @FXML
    private TextField weightTF;
    @FXML
    private TextField

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.