title: Creating a link to an Activity with a TextView
body: <p>I have an <code>Activity</code> called <code>MainActivity.java</code>, with an <code>activity_main.xml</code> file. But I don't know how to create a link that will launch another activity called <code>DirectionActivity</code>.  Below is a sample of my code.</p>
  
  <p>strings.xml</p>
  
  <pre><code> &lt;?xml version="1.0" encoding="utf-8"?&gt;
   &lt;resources&gt;
       &lt;string name="app_name"&gt;EEMA&lt;/string&gt;
       &lt;string name="action_settings"&gt;Settings&lt;/string&gt;
       &lt;string name="hello_world"&gt;The Emergency Evacuation Mobile App!&lt;/string&gt;
       &lt;string name="directions"&gt;\n\nTo view directions click here!&lt;/string&gt;
       &lt;string name="title_activity_direction"&gt;DirectionActivity&lt;/string&gt;
       &lt;string name="title_activity_main"&gt;MainActivity&lt;/string&gt;
  &lt;/resources&gt;
  </code></pre>
  
  <p>activity_main.xml textview</p>
  
  <pre><code>&lt;TextView  android:id="@+id/txtView"
      android:layout_width="fill_parent" 
      android:layout_height="wrap_content" 
      android:text="" 
      android:textSize="12sp"
      android:textColorLink="#FFFF00"
      android:textStyle="bold"
  /&gt;
  </code></pre>
  
  <p>MainActivity.java</p>
  
  <pre><code>public class MainMenuActivity extends Activity {
      public final static String EXTRA_MESSAGE = "com.example.myfirstapp.MESSAGE";
  
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.activity_main_menu);
  
          String str = "Please click here to view Directions";
          TextView txtView = (TextView) findViewById(R.id.txtView);
          txtView.setText(str);
          Linkify.addLinks(txtView, Linkify.ALL);     
      }
  
      @Override
      public boolean onCreateOptionsMenu(Menu menu) {
          // Inflate the menu; this adds items to the action bar if it is present.
          getMenuInflater().inflate(R.menu.main_menu, menu);
          return true;
      }
  }
  </code></pre>
  
  <p>DirectionActivity.java</p>
  
  <pre><code>public class DirectionActivity extends Activity {
  
      @SuppressLint("NewApi")
      @Override
      protected void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
  
          Intent intent = getIntent();
          String message = intent.getStringExtra(MainMenuActivity.EXTRA_MESSAGE);
  
          // Create the text view    
          TextView textView = new TextView(this);    
          textView.setTextSize(40);    
          textView.setText(message);
  
          // Set the text view as the activity layout    
          setContentView(textView);       
          setContentView(R.layout.activity_direction);
  
          // Make sure we're running on Honeycomb or higher to use ActionBar APIs        
          if (Build.VERSION.SDK_INT &gt;= Build.VERSION_CODES.HONEYCOMB) {            
              // Show the Up button in the action bar.            
              getActionBar().setDisplayHomeAsUpEnabled(true);        
          }       
      }
  }
  </code></pre>
  
  <p>So what is it I need to do to get the Please click here to view Directions to appear as a link that will open the DirectionActivity?</p>