How to go next activity 2nd activity on click in android studio

Tech Solution, Tutorial 0 Comments

How to go next activity 2nd activity on click in android studio open new activity on button click android studio on click image open new activity on button click android studio open new activity on button click android studio on click image

How to go next activity 2nd activity on click in android studio open new activity on button click android studio on click image open new activity on button click android studio open new activity on button click android studio on click image

<pre><code>

<Button
android:layout_marginTop=”10dp”
android:layout_width=”match_parent”
android:layout_height=”wrap_content”
android:layout_gravity=”center”
android:text=”New Registration”
android:onClick=”btn_signupform”/>

btn_signupform button name on click (android:onClick=”btn_signupform) file = activity_loginform.xml

function create name btn_signupform on click go to (signupform activity name = activity_signupform.xml)
call signupform activity name design form

public void btn_signupform(View view) // function create name btn_signupform

startActivity(new Intent(getApplicationContext(),signupform.class));

signupform = signupform.java file name (write in anyformate like: Signupform in first charactet in large size or may be use Sign_inform)

———-code show place check———-

package com.shriramedu.sikar.shriramedu;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.view.View;

public class loginform extends AppCompatActivity {

@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_loginform);
getSupportActionBar().setTitle(“Login Form”);
}

public void btn_signupform(View view) {

startActivity(new Intent(getApplicationContext(),signupform.class));

}

public void btn_website(View view) {

startActivity(new Intent(getApplicationContext(),webview.class));

}

}

</pre></code>

 

on click best used on image and button also How to go next activity 2nd activity on click in android studio

on click best used in image button How to go next activity 2nd activity on click in android studio

on click button id How to go next activity 2nd activity on click id in android studio

on click id How to go next activity 2nd activity on click image in android studio

 

How to go next activity 2nd activity on click in android studio open new activity on button click android studio on click image open new activity on button click android studio open new activity on button click android studio on click image