Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The default memory parameters that are used when starting the java
process for the Android designer might be incompatible with some system
configurations.
Starting with Xamarin Studio 5.7.2.7 (and later, Visual Studio for Mac) and Visual Studio Tools for Xamarin 3.9.344, these settings can be customized on a per-project basis.
New Android designer properties and corresponding Java options
The following property names correspond to the indicated java command-line option
AndroidDesignerJavaRendererMinMemory -Xms
AndroidDesignerJavaRendererMaxMemory -Xmx
AndroidDesignerJavaRendererPermSize -XX:MaxPermSize
Open your solution in Visual Studio.
Select each Android project one-by-one in the Solution Explorer and click Show All Files twice on each project. You can skip projects that do not contain any
.axmllayout files. This step will ensure that each project directory contains a.csproj.userfile.Quit Visual Studio.
Locate the
.csproj.userfile for each of the projects from step 2.Edit each
.csproj.userfile in a text editor.Add any or all of the new Android designer memory properties within a
<PropertyGroup>element. You can use an existing<PropertyGroup>or create a new one. Here's a complete example.csproj.userfile that includes all 3 attributes set to their default values:<?xml version="1.0" encoding="utf-8"?> <Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <PropertyGroup> <ProjectView>ProjectFiles</ProjectView> </PropertyGroup> <PropertyGroup> <AndroidDesignerJavaRendererMinMemory>128m</AndroidDesignerJavaRendererMinMemory> <AndroidDesignerJavaRendererMaxMemory>750m</AndroidDesignerJavaRendererMaxMemory> <AndroidDesignerJavaRendererPermSize>350m</AndroidDesignerJavaRendererPermSize> </PropertyGroup> </Project>Save and close all of the updated
.csproj.userfiles.Restart Visual Studio and reopen your solution.