We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

`Java.Lang.NoSuchMethodError` exception while using Navigation Drawer

I'm trying to create a navigation drawer from samples, but I get the following exception on android simulator.

>Java.Lang.NoSuchMethodError: no method with name='setClipToOutline' signature='(Z)V' in class Lcom/xamarin/forms/platform/android/FormsViewGroup;

This is my code:

    public class MainPage : ContentPage
        public MainPage()
            SfNavigationDrawer nav = new SfNavigationDrawer

            StackLayout mainStack = new StackLayout();
            mainStack.Opacity = 1;
            mainStack.Orientation = StackOrientation.Vertical;
            mainStack.HeightRequest = 500;
            mainStack.BackgroundColor = Color.White;

            ObservableCollection<String> list = new ObservableCollection<string>();

            ListView listView = new ListView();
            listView.WidthRequest = 200;
            listView.VerticalOptions = LayoutOptions.FillAndExpand;
            listView.ItemsSource = list;

            nav.DrawerContentView = mainStack;

            StackLayout headerLayout = new StackLayout();
            headerLayout.Orientation = StackOrientation.Vertical;
            headerLayout.BackgroundColor = Color.FromHex("#1aa1d6");
            headerLayout.VerticalOptions = LayoutOptions.CenterAndExpand;
            headerLayout.HorizontalOptions = LayoutOptions.CenterAndExpand;
            headerLayout.HeightRequest = 200;
            headerLayout.WidthRequest = 275;
            Image image = new Image();
            image.Source = ImageSource.FromFile("user.png");
            image.HeightRequest = 100;
            image.WidthRequest = 70;
            image.HorizontalOptions = LayoutOptions.CenterAndExpand;
            image.VerticalOptions = LayoutOptions.Center;
            image.BackgroundColor = Color.FromHex("#1aa1d6");

            Label header = new Label();
            header.Text = "James Pollock";
            header.FontSize = 20;
            header.HeightRequest = 30;
            header.WidthRequest = 140;
            header.TextColor = Color.White;
            header.HorizontalOptions = LayoutOptions.Center;
            header.VerticalOptions = LayoutOptions.Center;
            header.BackgroundColor = Color.FromHex("#1aa1d6");
            nav.DrawerHeaderView = headerLayout;

            Button imageButton = new Button();
            //imageButton.Source = (FileImageSource)ImageSource.FromFile("_menu_.png");
            imageButton.WidthRequest = 50;

            Label homeLabel = new Label();
            homeLabel.Text = "Home";
            homeLabel.FontSize = 15;
            homeLabel.TextColor = Color.White;
            homeLabel.HorizontalTextAlignment = TextAlignment.Center;
            homeLabel.VerticalTextAlignment = TextAlignment.Center;

            StackLayout headerFrame = new StackLayout();
            headerFrame.Orientation = StackOrientation.Horizontal;

            Label mainLabel = new Label();
            mainLabel.FontSize = 14;
            mainLabel.TextColor = Color.Black;
            mainLabel.Text = "Lorem ipsum dolor sit amet, lacus amet amet ultricies. Quisque mi venenatis morbi libero, orci dis, mi ut et class porta, massa ligula magna enim, aliquam orci vestibulum tempus. Turpis facilisis vitae consequat, cum a a, turpis dui consequat massa in dolor per, felis non amet. Auctor eleifend in omnis elit vestibulum, donec non elementum tellus est mauris, id aliquam, at lacus, arcu pretium proin lacus dolor et. Eu tortor, vel ultrices amet dignissim mauris vehicula. Lorem tortor neque, purus taciti quis id. Elementum integer orci accumsan minim phasellus vel.";

            StackLayout ContentFrame = new StackLayout();
            ContentFrame.Orientation = StackOrientation.Vertical;
            ContentFrame.BackgroundColor = Color.White;
            nav.ContentView = ContentFrame;

            nav.Position = Position.Left;
            nav.Transition = Transition.SlideOnTop;

            this.Content = nav;


I'll be thankful if you could help me get it working.

4 Replies

VV Vignesh V Syncfusion Team August 11, 2016 08:41 AM UTC

Hi Trinitro,

The reported crash issue might occur in older versions of Xamarin assemblies and so we request to check with upgraded xamarin version. We also suggest you to upgrade Essential Studio to our latest 2016 Volume 2 SP1 version which has the latest issue fixes. The latest ES version can be downloaded from the following link


Please let us know if the latest version fixes issue at your end.

Vignesh V

TR trinitro August 11, 2016 02:34 PM UTC

Hi Vignesh,

I'm using the latest Essential Studio, I'll let you know if upgrading Xamarin fixed the issue.

Thank you for your replay,

TR trinitro August 13, 2016 04:27 AM UTC

I'm using ES V ``, and latest release note doesn't include any information about this issue, so I'm assuming that this is a problem with Xamarin Form.

This are my packages:

<?xml version="1.0" encoding="utf-8"?>
  <package id="Xamarin.Android.Support.Design" version="" targetFramework="monoandroid60" />
  <package id="Xamarin.Android.Support.v4" version="" targetFramework="monoandroid60" />
  <package id="Xamarin.Android.Support.v7.AppCompat" version="" targetFramework="monoandroid60" />
  <package id="Xamarin.Android.Support.v7.CardView" version="" targetFramework="monoandroid60" />
  <package id="Xamarin.Android.Support.v7.MediaRouter" version="" targetFramework="monoandroid60" />
  <package id="Xamarin.Forms" version="" targetFramework="monoandroid60" />

When I want to update Xamarin from Nuget, I'll be facing this exception:

An outdated of 'Android SDK Build-tools' is in use which this version of Android Support Library does not support. You must uninstall any 'Android SDK Build-tools' versions older than 23.0.0 from the 'Tools' section in your 'Android SDK Manager' You also need to install 'Android SDK Build-tools' version 23.0.0 or higher. Invoice.Android

It's while I have only V `23.0.3` and `24.0` installed.

I know it's not a Syncfusion issue, but I'll be very grateful if you could possibly suggest some workarounds.

Thanks you.

AP Ashwini Paranthaman Syncfusion Team August 17, 2016 06:13 AM UTC

Hi Trinitro, 
As we are a US based business and therefore by law we cannot engage in any commercial transaction with businesses from Iran, we are regretfully unable to help you with this. 
Ashwini P. 

Live Chat Icon For mobile
Up arrow icon