function call from base adapter to its fragment class
<p>I am having a function in sherlock fragment class. I want to call it from its base adpater class when an item is clicked. My code bellow</p>

<p>In base adapter</p>

<pre><code>SherlockFragment obj=new TVgui()
(tvgui)obj.replace_fragment(frag,tag);
</code></pre>

<p>In  sherlockFragment class</p>

<pre><code> public void replace_fragment(SherlockFragment frag,String tag)
 {
frag_child = getChildFragmentManager();
ft = frag_child.beginTransaction();
    ft.addToBackStack(null)
    .replace(R.id.fragment_container,frag,tag);
    ft.commit();

}
</code></pre>

<p>Force close with error "Activity destroyed ". pls help</p>
