i have a fragmentactivity which calls other fragment by :
FragmentView1 f = (FragmentView1) this.getSupportFragmentManager()
.findFragmentByTag(getFragmentTag(0));
and my getFragmentTag() function is :
private String getFragmentTag(int pos){
return "android:switcher:"+R.id.viewpager+":"+pos; //fragmentpageradapter auto generated tag
}
not the problem is whenever i call f.somemethod , i get a nullpointerexception .
i tried with
Log.w("HELLO1",""+ f.getTag());
it return nullpointerexception .