- 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();
}
});