Quantcast
Channel: Recent Threads — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 204402

How to change event name in a Xamarin Android Binding

$
0
0

I am creating a Xamarin Android Binding of an android native library.What I have done so far is created .aar file and added into Jar folder of Xamarin Android Binding project but when I tried to build the project I got erros says "'CarouselView': member names cannot be the same as their enclosing type" What I found is after converting java code to C# wrapper CarouselView is a class which have an event with same class name i.e CarouselView.So that is the problem

I know by writing below line of code in MetaData file I can change the Class name of CarouselView to CarouselViewXamarin

attr path="/api/package[@name='com.jama.carouselview']/class[@name='CarouselView']" name="managedName">CarouselViewXamarin attr //Removed < > since code not showing with them

But I do not want to change the class name a better solution would be changing event name instead of whole class name I have gone through every documantation I can go with but didn't find anything for changing event name I can change method name but couldn'd find anything for to change event name

Here's my Github repo for project Try to build you will see the error double click on error you will see the event with the same name of class

Let me know if anyone can help me over this in changing event name note I can change the Class name and the code for that is comment in MetaData.xml file uncomment it and you would be able to build OK But what about changing event name


Viewing all articles
Browse latest Browse all 204402

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>