[mono-android] Custom AccordionView

Jonathan Pryor jonp at xamarin.com
Thu Oct 4 16:31:30 UTC 2012


On Oct 4, 2012, at 9:06 AM, javitxin <javier at externalia.com> wrote:
> Ok. At this point.. I assumed I have to include all necessary resources from
> the gihub project... I mean layouts and drawable...

You also need to ensure that you include your accordionView.jar as an AndroidJavaLibrary in your Application project:

	http://docs.xamarin.com/android/advanced_topics/Java_Integration_Overview/Binding_a_Java_Library_(.jar)#Add_the_Jar_to_the_Project

> Then I create this layout to use my accordion but two things:
> 
> One: my layout object(package.objectView) is blue underlined saying that the main layout has an invalid secondary element... but it compiles..
> 
> When executing it crashes with this exception...
> 
> "Binary XML file line #1: Error inflating class" 

As always, the FULL stack trace would be helpful:

	http://docs.xamarin.com/android/advanced_topics/android_debug_log

I'd guess that it's a java.lang.NoClassDefFoundError (or similar) because com.egestionamobile.accordionview.widget.AccordionView can't be found. If that's the case, then adding accordionView.jar to your project with an AndroidJavaLibrary build action should fix it.

 - Jon



More information about the Monodroid mailing list