title: Android: remove() Fragment--> add() new Fragment of same class again ->onCreateView and onActivityCreated not called?
body: <p>I am destroying a programmatically created fragment with:</p>
  
  <pre><code>getFragmentManager().beginTransaction().remove(getFragmentManager().findFragmentById(R.id.test)).commit();
  </code></pre>
  
  <p>Which is determined in the xml file like this:</p>
  
  <pre><code>&lt;LinearLayout
      android:id="@+id/test"
      android:orientation="horizontal"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"&gt;
  
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>If I then create a fragment from the same class again in the mainactivity:</p>
  
  <pre><code>getSupportFragmentManager().beginTransaction()
              .add(R.id.result_bar, testinstance)
              .commit();
  </code></pre>
  
  <p>Then onCreate seem not called again (the fragment is just empty). What am I doing wrong here? Thanks.</p>