- Forum posts: 6
Dec 15, 2015, 12:46:23 PM via Website
Dec 15, 2015 12:46:23 PM via Website
I am trying to develop a textbox which once the user clicks on the textbox it need to direct them to another activity I have tried to use the onclickListener method which crashes the application once clicked on the textbox.
Could you please advise.
forgotpasstxt= (TextView) findViewById(R.id.txtForgotpPass);
forgotpasstxt.setonclickListener(new View.onclickListener() {
public void onclick(View view) {
Intent myIntent = new Intent(view.getContext(), ChangePassword.class);
startActivityForResult(myIntent, 0);
finish();
}
});
Recommended editorial content
With your consent, external content is loaded here.
By clicking on the button above, you agree that external content may be displayed to you. Personal data may be transmitted to third-party providers in the process. You can find more information about this in our Privacy Policy.