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 6669747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T03:11:13+00:00 2026-05-26T03:11:13+00:00

My program is not working well, and I don’t understand why, mind helping out

  • 0

My program is not working well, and I don’t understand why, mind helping out please?

    package project.ernest;

 import android.app.Activity;
 import android.content.Intent;
 import android.os.Bundle;

 public class Part1 extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) 
    {
       super.onCreate(savedInstanceState);
       setContentView(R.layout.main);
    }
    Intent DisclaimerHandler = new Intent(getBaseContext(), Part2.class);
    {
    Part1.this.startActivity(DisclaimerHandler);
   }
} 

I have 2 .java file, namely, Part1 and Part2.
as well as a .xml file name disclaimer placed under layout

I tried to run it, but it gave me a force stop.

  • 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-05-26T03:11:13+00:00Added an answer on May 26, 2026 at 3:11 am

    use like this..

     package project.ernest;
    
     import android.app.Activity;
     import android.content.Intent;
     import android.os.Bundle;
    
     public class Part1 extends Activity {
        /** Called when the activity is first created. */
        @Override
        public void onCreate(Bundle savedInstanceState) 
        {
           super.onCreate(savedInstanceState);
           setContentView(R.layout.main);
    
          final Button gs = (Button) findViewById(R.id.save); 
          gs.setOnClickListener(new View.OnClickListener() {
            public void onClick(View view) { 
                Intent i = new Intent(getBaseContext(), Part2.class);         
                Part1.this.startActivity(i);    
            }
        });          
    } 
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

new here, I'm working on a program for port scanning, TCP works well, but
I am working on a quite big project: The program has to do multiple
i need to hide a windows program (not visible in taskbar, system tray. visible
I would like to add a QMenuBar to a window of my program (not
I want to compile a "Hello World" MS-DOS exe. Not a program that runs
I am not really familiar with Maven program but I've been using Eclipse for
I'm not really asking about how programmers learn how to program. More about specific
I'm making a program which the user build directories (not in windows, in my
For some reason this program is saying that 'switch' is not defined. What is
How stable is WPF not in terms of stability of a WPF program, but

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.