I see this error when emulating my application on Android
[ERROR] TiExceptionHandler: (main) [90,2129] Binary XML file line #5: Binary XML file line #5: Error inflating class android.support.v4.widget.DrawerLayout
[ERROR] TiExceptionHandler:
[ERROR] TiExceptionHandler: org.appcelerator.titanium.TiApplication$1.uncaughtException(TiApplication.java:366)
[ERROR] TiExceptionHandler: org.appcelerator.titanium.TiBaseActivity.onCreate(TiBaseActivity.java:769)
[ERROR] TiExceptionHandler: org.appcelerator.titanium.TiActivity.onCreate(TiActivity.java:47)
[ERROR] TiExceptionHandler: android.app.Activity.performCreate(Activity.java:6975)
[ERROR] TiExceptionHandler: android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1213)
[ERROR] TiExceptionHandler: android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2770)
[ERROR] TiExceptionHandler: android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2892)
[ERROR] TiExceptionHandler: android.app.ActivityThread.-wrap11(Unknown Source:0)
[ERROR] TiExceptionHandler: android.app.ActivityThread$H.handleMessage(ActivityThread.java:1593)
[ERROR] TiExceptionHandler: android.os.Handler.dispatchMessage(Handler.java:105)
titanium version 11.1.1 SDK
2
Answers
this is my build.gradle code
The error message you provided indicates an issue with inflating the
DrawerLayout
class from theandroid.support.v4.widget
(This error is typically encountered when there is a mismatch between the support library versions used in your project.)I would recomend updating Titanium SDK: As you mentioned you are using Titanium version 11.1.1 SDK, it’s worth considering updating to a newer version of the Titanium SDK. Newer versions often include bug fixes and compatibility improvements, which may resolve the issue you are facing.
If that does not work I would review your layout XML file: