cancel
Showing results for 
Search instead for 
Did you mean: 

Gear VR AndroidManifest.xml troubles ClassNotFoundException

Foundry45
Explorer
I ran into some trouble with my AndroidManifest.xml... my app would just immediately crash. When I looked at the logs, the error was something like

 
AndroidRuntime: Caused by: java.lang.ClassNotFoundException: Didn't find class "com.mycompany.myappname.myAppProductName" on path: DexPathList[[zip file "/data/app/com.mycompany.myappname-2/base.apk"]
My AndroidManifest.xml was like this:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.mycompany.myappname">

    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

<application android:icon="@drawable/app_icon" android:label="@string/app_name">
   <activity
     android:name="myAppProductName"
     android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen"
     android:label="@string/app_name"
     android:launchMode="singleTask"
     android:screenOrientation="landscape"
     android:configChanges="screenSize|orientation|keyboardHidden|keyboard"
     android:excludeFromRecents="true">
     <intent-filter>
      <action android:name="android.intent.action.MAIN" />
      <category android:name="android.intent.category.INFO" />
     </intent-filter>
    </activity>
 </application>

<meta-data
      android:name="com.samsung.android.vr.application.mode"
      android:value="vr_only"/>

</manifest>



The key to fixing it was changing the android:name under activity to:




<activity     android:name="com.unity3d.player.UnityPlayerActivity"

1 REPLY 1

juanoldinho
Heroic Explorer
Thanks for the tip, it may be useful for other devs who are having trouble with their manifest file. 
Please tag me, @juanoldinho, in your forum post/response if you need immediate assistance or want additional support or context on an issue you are having with our software or integrations.

Having an issue with our platform, services, or integrations?

Try using our new bug tool to report this and receive emailed updates as we proceed to address it internally.