报错:Can not perform this action after onSaveInstanceState
原因:fragmenttransaction的commit方法调用报错
解决方案:替换commitNow为commitNowAllowingStateLoss
参考:https://blog.youkuaiyun.com/swer0808/article/details/92985282
问题记录:Can not perform this action after onSaveInstanceState
最新推荐文章于 2025-06-17 09:46:54 发布
本文详细解析了在使用FragmentTransaction的commit方法时遇到的“Cannot perform this action after onSaveInstanceState”错误,介绍了错误产生的原因,并提供了将commit替换为commitNowAllowingStateLoss的解决方案。
511

被折叠的 条评论
为什么被折叠?



