Exception is:
"Unable to resolve superclass of L android/support/v4/app/FragmentTransitionCompat21$1;"
I am trying to Pop the last Fragment Transition from the Fragment Manager's Fragment Back Stack, using the following function:
getSupportFragmentManager().popBackStack();
,
When I did this, function call throwing following Error. This is only happening when I used New Android API Version 21 as Build target.
Same Code work fine with Older API Version 20.
Error: Could not find superclass of 'android.support.v4.app.FragmentTransitionCompat21$1'
It seems an Inner Class in the Base class of 'FragmentTransitionCompat21'.
Error:
W/dalvikvm(1356): Unable to resolve superclass of Landroid/support/v4/app/FragmentTransitionCompat21$1; (1082)
W/dalvikvm(1356): Link of class 'Landroid/support/v4/app/FragmentTransitionCompat21$1;' failed
E/dalvikvm(1356): Could not find class 'android.support.v4.app.FragmentTransitionCompat21$1', referenced from method android.support.v4.app.FragmentTransitionCompat21.setEpicenter
W/dalvikvm(1356): VFY: unable to resolve new-instance 358 (Landroid/support/v4/app/FragmentTransitionCompat21$1;) in Landroid/support/v4/app/FragmentTransitionCompat21;
Does anybody find similar Error? please help how to solve this, thank you.
It definitely referencing API 21 Version 4 Support Library, if you have any animations set on the transaction that has ObjectAnimator change it, also reference your animations from R.anim, or it will through and error.
in few previous days i have also face this kind of err, then i try v7 appcompat with API 22 instead of android.support.v4.app.FragmentTransition.
have you try this one,
import android.app.FragmentTransaction;
there is code snip.
FragmentManager fm = getFragmentManager();
FragmentTransaction fragmentTransaction = fm.beginTransaction();
fragmentTransaction.addToBackStack("");
fragmentTransaction.replace(R.id.content_frame, Fr);
fragmentTransaction.commit();
if you are trying to pop up fragment from stack inside the fragment you should use getChildFragmentManager instead of getfragmentManager.
[https://stackoverflow.com/questions/6847460/fragments-within-fragments][1]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With