Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting OutOfMemoryException in Xamarin

java.lang.OutOfMemoryError. Consider increasing the value of $(JavaMaximumHeapSize). Java ran out of memory while executing 'java.exe'

I am getting out of memory exception in my visualstudio Xamarin Project Please help me how can i resolve this issue.

like image 445
Srinivas Ch Avatar asked Apr 25 '16 08:04

Srinivas Ch


People also ask

How do you resolve Outofmemoryexception in xamarin?

I would increase your build heap size. Right click your Android Project > Properties > Android Options > Advanced > Java Max Heap Size.

How to handle out of memory exception in Android?

If you haven't seen any OOM in your Android application, then you are going to have one in future. The OutOfMemoryError comes in Android due to memory leaks. So, in order to remove the OutOfMemoryError, you need to remove memory leaks from your Android application.

How can we avoid Outofmemory exception?

OutOfMemoryError: Java heap space. 1) An easy way to solve OutOfMemoryError in java is to increase the maximum heap size by using JVM options "-Xmx512M", this will immediately solve your OutOfMemoryError.


1 Answers

I would increase your build heap size.

Right click your Android Project > Properties > Android Options > Advanced > Java Max Heap Size.

enter image description here

like image 105
Iain Smith Avatar answered Sep 18 '22 15:09

Iain Smith