title: textbox doesnt exist in current context
body: <p>getting an error for every textbox on the page saying that it doesn't exist in the current context on default.aspx.cs even though they are present within default.aspx</p>
  
  <pre><code>    &lt;%@ Page Language="C#" AutoEventWireup="true" CodeFile="default.aspx.cs" Inherits="_Default" %&gt;
  
  &lt;!DOCTYPE html&gt;
  
  &lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
  &lt;head runat="server"&gt;
      &lt;title&gt;&lt;/title&gt;
  
      &lt;link rel="stylesheet" type="text/css" href="css/bootstrap.css" media="all" /&gt;
      &lt;link rel="stylesheet" type="text/css" href="css/bootstrap-theme.css" media="all" /&gt;
      &lt;link rel="stylesheet" type="text/css" href="css/style.css" media="all" /&gt; 
  &lt;/head&gt;
  &lt;body&gt;
  
      &lt;form id="form1" runat="server"&gt;
  
          &lt;table&gt;
              &lt;tr&gt;
                  &lt;td&gt;&lt;asp:Label ID="lblTemperature" runat="server" Text="Temperature"&gt;&lt;/asp:Label&gt;&lt;/td&gt;
                  &lt;td&gt;&lt;asp:TextBox ID="txtTemp" runat="server" Height="20px" Width="101px"&gt;&lt;/asp:TextBox&gt;&lt;/td&gt;
              &lt;/tr&gt;
              &lt;tr&gt;
                  &lt;td&gt;&lt;asp:Button ID="btnCalc" runat="server" OnClick="Button1_Click" Text="Calculate Score" /&gt;&lt;/td&gt;
                  &lt;td&gt;&lt;asp:Label ID="lblScore" runat="server" Text=""&gt;&lt;/asp:Label&gt;&lt;/td&gt;
              &lt;/tr&gt;
              &lt;tr&gt;
                  &lt;td&gt;&lt;asp:Label ID="lblAlert" runat="server" Text=""&gt;&lt;/asp:Label&gt;&lt;/td&gt;
              &lt;/tr&gt;
          &lt;/table&gt;
  
      &lt;/form&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>and my default.aspx.cs each time it throws the error saying that the text boxes and labels do not exist in the current context</p>
  
  <pre><code>using System;
  using System.Collections.Generic;
  using System.Linq;
  using System.Web;
  using System.Web.UI;
  using System.Web.UI.WebControls;
  using System.Drawing;
  
  public partial class _Default : System.Web.UI.Page
  {
  
  protected void Page_Load(object sender, EventArgs e)
  {
  
  }
  
  
  protected void Button1_Click(object sender, EventArgs e)
  {       
          int score;
          score = 0;
          //CHECK TEMP IS VALID
          double Temp;
          if (double.TryParse(txtTemp.Text, out Temp))
          { //SUCCESS
          }
          else
          {
              //FAIL
          }
  
          //TEMP RATE CALC
          if (Temp &lt;= 35.0)
          {
              score = score + 3;
          }
          else if (Temp &gt;= 35.1 &amp;&amp; Temp &lt;= 36.0)
          {
              score = score + 1;
          }
          else if (Temp &gt;= 36.1 &amp;&amp; Temp &lt;= 38.0)
          {
              score = score + 0;
          }
          else if (Temp &gt;= 38.1 &amp;&amp; Temp &lt;= 39.0)
          {
              score = score + 1;
          }
          else if (Temp &gt;= 39.1)
          {
              score = score + 2;
          }
  
          //WriteScore
          lblScore.Text = score.ToString();
  
  
          if (score &lt;= 1)
          {
              lblAlert.Text = "GREEN";
              lblAlert.ForeColor = Color.Green;
          }
          else if (score &gt;= 2 &amp;&amp; score &lt;= 4)
          {
              lblAlert.Text = "AMBER";
              lblAlert.ForeColor = Color.Orange;
          }
          else if (score &gt;= 5)
          {
              lblAlert.Text = "RED";
              lblAlert.ForeColor = Color.Red;
  
          }
  
  }
  
  }
  </code></pre>