Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9298635
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T22:22:16+00:00 2026-06-18T22:22:16+00:00

I’m quite new to programming and have just hit a simple road block that

  • 0

I’m quite new to programming and have just hit a simple road block that is holding me up. I am trying to have a button from my main activity call up another activity. I’ve researched but as yet I haven’t found something to work (probably really simple and stupid). Any help would be appreciated. I’ve included the code for my main activity. Thank you

package com.example.valentinetimer;


import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;


public class CardFront extends Activity implements OnClickListener {

    private static final String TAG = null;

    Button openButton;

    @Override
    public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.cardfrontxml);

    Log.d(TAG, "onCreate");

    //Button
    openButton = (Button) findViewById(R.id.openButton);
    openButton.setOnClickListener(this);

    this.setContentView(R.layout.cardfrontxml);
    this.openButton = (Button)this.findViewById(R.id.openButton);
    this.openButton.setOnClickListener(new OnClickListener()
    {
        @Override
        public void onClick(View v)
        {
            Log.d(TAG, "Click Event");

            Intent intent = new Intent (null, CardContent.class);
            startActivity (intent);
        }
    });
    //End Button

}

    @Override
    public void onClick(View v)
    {
        // TODO Auto-generated method stub  
    }
}

LogCat:

02-08 10:18:51.927: E/AndroidRuntime(2494): FATAL EXCEPTION: main
02-08 10:18:51.927: E/AndroidRuntime(2494): android.content.ActivityNotFoundException:          Unable to find explicit activity class   {com.example.valentinetimer/com.example.valentinetimer.CardContent}; have you declared this   activity in your AndroidManifest.xml?
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1504)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.app.Instrumentation.execStartActivity(Instrumentation.java:1382)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.app.Activity.startActivityForResult(Activity.java:3095)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.app.Activity.startActivity(Activity.java:3201)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at com.example.valentinetimer.CardFront$1.onClick(CardFront.java:42)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.view.View.performClick(View.java:3110)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.view.View$PerformClick.run(View.java:11928)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.os.Handler.handleCallback(Handler.java:587)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.os.Handler.dispatchMessage(Handler.java:92)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.os.Looper.loop(Looper.java:132)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at android.app.ActivityThread.main(ActivityThread.java:4025)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at java.lang.reflect.Method.invokeNative(Native Method)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at java.lang.reflect.Method.invoke(Method.java:491)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:841)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599)
02-08 10:18:51.927: E/AndroidRuntime(2494):     at dalvik.system.NativeStart.main(Native Method)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T22:22:17+00:00Added an answer on June 18, 2026 at 10:22 pm

    The problem is that your CardContent class is not specified in your manifest correctly. Please add this to your manifest in the application tag:

    <activity
        android:name=".CardContent">
    </activity>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have just tried to save a simple *.rtf file with some websites and
I have a small JavaScript validation script that validates inputs based on Regex. I
I have a French site that I want to parse, but am running into
I am doing a simple coin flipping experiment for class that involves flipping a
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I have a text area in my form which accepts all possible characters from
I'm trying to convert HTML to plain text. I get many &\#8217; &\#8220; etc.
I'm trying to decode HTML entries from here NYTimes.com and I cannot figure out
I have a view passing on information from a database: def serve_article(request, id): served_article
I'm trying to create an if statement in PHP that prevents a single post

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.