title: TextView.setText() throwing NullPointerException
body: <p>I'm trying to set the text of a <code>TextView</code> which sounds simple enough but it keeps throwing errors here's my function:</p>
  
  <pre><code>private void getAndPutNum(){
      TelephonyManager tm = (TelephonyManager)getSystemService(Context.TELEPHONY_SERVICE);
      String myNum = tm.getLine1Number();
      TextView numDisplay = (TextView)findViewById(R.id.myNum);
      try{
          numDisplay.setText(myNum);
      }catch(Exception e){
          Toast.makeText(getApplicationContext(), "ERROR", Toast.LENGTH_LONG).show();
          e.printStackTrace();
      }
  }
  </code></pre>
  
  <p>I've set <code>READS_PHONE_STATE</code> in my 'Uses Permission' of my Manifest. Can anyone see what I might be doing wrong?</p>
  
  <p><strong>UPDATE:</strong><br>
  Here's my layout code:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:orientation="vertical"
  android:layout_width="fill_parent"
  android:layout_height="fill_parent" android:weightSum="1"&gt;
  &lt;TextView android:gravity="center|center_vertical|center_horizontal" android:textAppearance="?android:attr/textAppearanceLarge" android:text="@string/number" android:textSize="65px" android:layout_gravity="center|center_vertical|center_horizontal" android:layout_height="fill_parent" android:layout_weight=".8" android:layout_width="fill_parent" android:layout_marginTop="-40dp" android:keepScreenOn="true" android:id="@+id/myNum"&gt;&lt;/TextView&gt;
  </code></pre>
  
  <p></p>