简体   繁体   English

Xamarin Forms Android 出 Z93F725A07423FE1C889F448B33Demory1F46 异常

[英]Xamarin Forms Android out java.lang.OutOfMemoryError exception

I have an Xamarin Forms Android App in the version version 2.5.1.527436 and now I want to upgrade the Xamarin Forms version to 5.0.0.2012 to update the controls used in the app and improve it. I have an Xamarin Forms Android App in the version version 2.5.1.527436 and now I want to upgrade the Xamarin Forms version to 5.0.0.2012 to update the controls used in the app and improve it.

After updating the Xamarin forms version to 5.0.0.2012, I am facing the Java.lang.将Xamarin forms版本更新到5.0.0.2012后,我面对的是Java.lang。 Out of memory exceptions in the starting page of the app after the splash screen.在启动屏幕后的应用程序的起始页面中出现 memory 异常。 Below is the crash report.以下是崩溃报告。

java.lang.OutOfMemoryError: Failed to allocate a 7814092184 byte allocation with 1912926 free bytes and 510MB until OOM, max allowed footprint 3825854, growth limit 536870912
at crc643f46942d9dd1fff9.ButtonRenderer_ButtonClickListener.n_onClick(Native Method)
at crc643f46942d9dd1fff9.ButtonRenderer_ButtonClickListener.onClick(ButtonRenderer_ButtonClickListener.java:30)
at android.view.View.performClick(View.java:6304)
at android.view.View$PerformClick.run(View.java:24803)
at android.os.Handler.handleCallback(Handler.java:794)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:176)
at android.app.ActivityThread.main(ActivityThread.java:6635)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:547)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:823)

I have tried the below solutions and it does not fix the problem.我尝试了以下解决方案,但并不能解决问题。

How to fix Java.Lang.OutOfMemoryError in Xamarin.Forms android application? 如何修复 Xamarin.Forms ZC3FCZD3759213819Z.Lang.OutOfMemoryError 中的 Java.Lang.OutOfMemoryError?

Android:java.lang.OutOfMemoryError: Failed to allocate a 23970828 byte allocation with 2097152 free bytes and 2MB until OOM Android:java.lang.OutOfMemoryError: 无法分配 23970828 字节分配与 2097152 空闲字节和 2MB 直到 OOM

Why does the exception occur?为什么会出现异常?

Making an update that big sometimes is hard.有时很难进行如此大的更新。 You can try doing a small upgrade first, let's say to Xamarin.Forms 4, if the problem is solved, you might want to go to XF 4.8 or directly to 5.0.你可以先尝试做一个小升级,比如说Xamarin.Forms 4,如果问题解决了,你可能想Z34D1F91FB2E514B8576FAB1A745A89A6B.80直接升级到XF。

You can go to any version that you like, but then your final goal will be 5.0您可以 go 到您喜欢的任何版本,但您的最终目标将是 5.0

The solutions that you posted about the specific error, increase the heap.您发布的有关特定错误的解决方案增加了堆。 But maybe you should try to look for the cause of the error.但也许你应该尝试寻找错误的原因。 It can be at your App class, or maybe your XAML, but trying to optimize it it's also a good practise它可以在您的应用程序 class 或 XAML 中,但尝试优化它也是一个好习惯

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何修复 Xamarin.Forms ZC3FCZD1503617ECCE5A8 中的 Java.Lang.OutOfMemoryError 错误? - How to fix Java.Lang.OutOfMemoryError in Xamarin.Forms android application? Android上的Xamarin.Forms ListView OutOfMemoryError异常 - Xamarin.Forms ListView OutOfMemoryError exception on Android Android动画列表-简单示例抛出java.lang.OutOfMemoryError - Android Animation List - Simple Example throws java.lang.OutOfMemoryError Xamarin android部署上的Java,Lang.OutOfMemoryError - Java,Lang.OutOfMemoryError on Xamarin android deployment Xamarin Android - OutOfMemoryError异常 - 大图像 - Xamarin Android - OutOfMemoryError exception - large image Xamarin形成内存不足的Android - Xamarin Forms Out Of Memory Android Xamarin Forms错误:Java.Lang.NoClassDefFoundError:android.support.graphics.drawable.VectorDrawableCompat - Xamarin Forms error: Java.Lang.NoClassDefFoundError: android.support.graphics.drawable.VectorDrawableCompat PushWoosh Xamarin在注册时出现Android异常 - PushWoosh Xamarin Forms Android exception on registration Java.Lang.NoClassDefFoundError:超时超过了获取异常详细信息Xamarin Android - Java.Lang.NoClassDefFoundError: Timeout exceeded getting exception details Xamarin Android 哈马林。 安卓权限。 CheckSelfPermission() 异常 Java.Lang.NullPointerException - Xamarin. Android permissions. CheckSelfPermission() exception Java.Lang.NullPointerException
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM