Forum Xamarin.Android

How to convert C# List to Java IIterable

I have some LatLng point in a c# list. I want to use below code:

PolygonOptions  rectOptions = new PolygonOptions();
            rectOptions.AddAll   (val);

but because AddAll() method get IIterable method I can not use it.

Actually I want to use AddAll because in the topic I link below, the writer of the accepted answer used this method. I'm not aware of what is diffrence between Add() method and AddAll() method but when I use Add() method my result is not same with what you see in the image of link. So I tried to use AddAll() method that faced with this error.


  • JPMcWhiskersJPMcWhiskers USMember ✭✭

    This is old, but if anyone is working with Maps and needs to add an IIterable array for using AddHole(IIterable), you can do this:

    Java.Util.ArrayList al = new Java.Util.ArrayList(--A C# array--);

Sign In or Register to comment.