title: Output not able to show at UI
body: <p>I'm currently trying to write an app to calculate BMI and calories needed by a person (male / female).
  My apps have 2 parts:
  1. BMI calculation
  2. Calories needed</p>
  
  <p>The first part works well (so I excluded the code for this part), but for the 2nd part, calories needed calculation, it is not able to show up the result as expected (after I click on 'calories needed' button). Probably something is still missing but I cant find it so far.</p>
  
  <p>Everything looks fine in the code, no error.
  Can anyone help to have a look on it? :) thanks in advance.</p>
  
  <p>Code as below:</p>
  
  <pre><code>package com.example.caloriescalculator;
  
  import android.app.Activity;
  import android.os.Bundle;
  import android.view.View;  
  import android.view.View.OnClickListener;  
  import android.widget.Button;
  import android.widget.EditText;
  import android.widget.TextView;
  import android.widget.RadioButton;
  
  public class BMIcalculation extends Activity
  {
  EditText weightE;
  EditText heightE ;
  EditText ageE ;
  TextView caloriesresult ;
  RadioButton male; 
  RadioButton female;
  
  Button calories;
  
  EditText weightText ;
  EditText heightText ;
  EditText ageText;
  TextView resultText;
  
  @Override
  public void onCreate(Bundle savedInstanceState) 
  {
      super.onCreate(savedInstanceState); 
      setContentView(R.layout.bmilayout_main);     
  
      weightE = (EditText)findViewById(R.id.weightText);
      heightE = (EditText)findViewById(R.id.heightText);
      ageE = (EditText)findViewById(R.id.ageText);
      caloriesresult = (TextView)findViewById(R.id.caloriesText);
      male = (RadioButton) findViewById(R.id.maleradio); 
      female = (RadioButton) findViewById(R.id.femaleradio);
  
      Button calories = (Button) findViewById(R.id.caloriesButton); 
      calories.setOnClickListener(new OnClickListener() 
         {
           @Override
                  public void onClick(View arg0) 
                  {    
                      int caloriesneed = 0, weight = 0, height = 0, age = 0;
  
                      try {
                              if ((!weightE.equals("")) &amp;&amp; (!heightE.equals("")) &amp;&amp; (!ageE.equals(""))) 
                                  {
                                  weightE = (EditText) findViewById(R.id.weightText);  
                                  weight = Integer.parseInt(weightE.getText().toString().trim());     
                                  heightE = (EditText) findViewById(R.id.heightText);  
                                  height = Integer.parseInt(heightE.getText().toString().trim());
                                  ageE = (EditText) findViewById(R.id.ageText);  
                                  age = Integer.parseInt(ageE.getText().toString().trim());
  
                                      if (male.isSelected()) 
                                          {
                                              caloriesneed = (int) Math.round (655 + 9.6*weight + 1.8*height - 4.7*age);                                       
                                              caloriesresult.setText(caloriesneed);
                                          }
  
                                      else if (female.isSelected())
                                          {
                                              caloriesneed = (int) Math.round (66 + 13.7*weight + 5*height - 6.8*age);
                                              caloriesresult.setText(caloriesneed);
                                          }
                                  }
                           } 
                       catch (Exception k)
                       { System.out.println(k);
  
                       }
  
                  }
         });
  }
  </code></pre>