I am trying to integrate Android Google Play Services
from the Android docs. I got all the steps working and it compiles with no errors. At runtime on my splash screen, I get the below error.
05-30 21:08:36.115: E/AndroidRuntime(7137): FATAL EXCEPTION: Thread-153
05-30 21:08:36.115: E/AndroidRuntime(7137): java.lang.NoClassDefFoundError: matt.lyons.bibletrivia.lite.MainMenu
05-30 21:08:36.115: E/AndroidRuntime(7137): at matt.lyons.bibletrivia.lite.SplashScreen$IntentLauncher.run(SplashScreen.java:46)
Below is the code to "SplashScreen.java:46".
Intent intent = new Intent(SplashScreen.this, MainMenu.class); //Line 46
startActivity(intent);
I just changed the opening line in my MainMenu
from this:
public class MainMenu extends Activity {
to this:
public class MainMenu extends BaseGameActivity {
And now I am getting the ClassNotFoundException. Why is this error popping up? The MainMenu
class is definitely there. More code can be provided upon request.
Android Manifest
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="matt.lyons.bibletrivia.lite"
android:versionCode="5"
android:versionName="1.2.1" >
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="15" />
<application
android:icon="@drawable/icon_blue_bg"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name=".SplashScreen"
android:screenOrientation="portrait" >
<intent-filter>
<action
android:name="android.intent.action.MAIN" />
<category
android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.google.ads.AdActivity"
android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize" />
<activity
android:label="@string/app_name"
android:name=".About"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Categories"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Question"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Quiz"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".QuestionView"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Results"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".Highscores"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".DatabaseHelper"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".ComingSoon"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".MainMenu"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".MyApplication"
android:screenOrientation="portrait" />
<activity
android:label="@string/app_name"
android:name=".BibleStudy"
android:screenOrientation="portrait" />
</application>
<uses-permission
android:name="android.permission.INTERNET" />
<uses-permission
android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission
android:name="com.android.vending.BILLING" />
</manifest>