title: variables int m_height; int m_weight; are zero
body: <p>So i just started with C#. I thought i would write a little BMI calculator. 
  My Problem: both variables int m_height; int m_weight; are zero. Am i supposed to initialize them differently? If so, how? Am i missing something else?  </p>
  
  <pre><code>public partial class MainWindow : Window
  {
      public MainWindow()
      {
          InitializeComponent();
      }
  
      int m_height; 
      int m_weight;
  
      public int Height
      {
          get { return m_height; }
          set { this.m_height = Convert.ToInt32(txtHeight.Text); } 
      }
  
      public int Weight
      {
          get { return m_height;  }
          set { this.m_weight = Convert.ToInt32(txtWeight.Text);  }
      }
  
      private void btnSubmit_Click(object sender, RoutedEventArgs e)
      {
          int result = m_weight  / ((int)Math.Pow(m_height, 2));
          txOutput.Text = result.ToString();
      }
  }
  </code></pre>
  
  <pre><code>&lt;Window x:Class="testApp.MainWindow"
          xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
          xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
          xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
          xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
          xmlns:local="clr-namespace:testApp"
          mc:Ignorable="d"
          Title="MainWindow" Height="450" Width="800"&gt;
      &lt;Grid&gt;
          &lt;TextBox HorizontalAlignment="Left" Height="23" TextWrapping="Wrap" Text="" Name="txtHeight" VerticalAlignment="Top" Width="120" Margin="101,129,0,0"/&gt;
          &lt;TextBox HorizontalAlignment="Left" Height="23" TextWrapping="Wrap" Text="" Name="txtWeight" VerticalAlignment="Top" Width="120" Margin="362,129,0,0" /&gt;
          &lt;TextBox HorizontalAlignment="Left" Height="23" TextWrapping="Wrap" Text="" Name="txOutput" VerticalAlignment="Top" Width="120" Margin="232,318,0,0" /&gt;
          &lt;Button Content="Sumbit" Name="btnSubmit" HorizontalAlignment="Left" VerticalAlignment="Top" Width="75" Margin="256,223,0,0" Click="btnSubmit_Click" /&gt;
          &lt;Label Content="Your Height:&amp;#xD;&amp;#xA;" HorizontalAlignment="Left" VerticalAlignment="Top" RenderTransformOrigin="3.089,2.829" Margin="101,99,0,0" Width="120"/&gt;
          &lt;Label Content="Your Weight:&amp;#xA;Your Weight" HorizontalAlignment="Left" VerticalAlignment="Top" RenderTransformOrigin="3.089,2.829" Margin="362,99,0,0" Width="120" Height="24"/&gt;
  
      &lt;/Grid&gt;
  &lt;/Window&gt;
  </code></pre>