title: Return to app after call ends
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/1556987/how-to-make-a-phone-call-in-android-and-come-back-to-my-activity-when-the-call-i">How to make a phone call in android and come back to my activity when the call is done?</a>  </p>
  </blockquote>
  
  
  
  <p>The call is being initiated from the app via <code>startActivity(new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + phNo)));</code>. After the call ends, I do not return to the app, but to the phone's desktop.</p>
  
  <p>What am I doing wrong? Is it possible to return to the app that has initiated the call? I am not sure if this is allowed in Android. </p>
  
  <p>EDIT:
  Code added</p>
  
  <pre><code>@Override
  protected void onListItemClick(ListView l, View v, int position, long id) {
      super.onListItemClick(l, v, position, id);
  
  switch ((int) id) {
      case 0:
          try {
              TextView txtCallDisp = (TextView) findViewById(R.id.itmDdd);
              startActivity(new Intent(Intent.ACTION_CALL, Uri.parse("tel:" + phNo)));
          } catch (NullPointerException e) {
              e.printStackTrace();
          } catch (Exception ee) {
              ee.printStackTrace();
          }
          break;
      //... other switch statements
  </code></pre>