title: How to clear Fragment backstack in android
body: <p>hi how to clear fragment back stack am using below logic it's not working...</p>
  
  <pre><code>for(int i = 0; i &lt; mFragmentManager.getBackStackEntryCount(); ++i) {            
       mFragmentManager.popBackStack();
  }
  </code></pre>
  
  <p>help me..</p>