How do i make username and password file in androoid
<p>I take two edit text and one button. I want to set a particular username and password, and when i click on the button if the username and password is correct then open a new intent otherwise display a toast.</p>

<p>i use this code to display different  toast but it not works. it always display "incorrect".</p>

<pre><code>b.setOnClickListener(new OnClickListener() {

    public void onClick(View v) {
        // TODO Auto-generated method stub
        if((e.getText().toString()=="nishant")&amp;&amp;(e1.getText().toString()=="pawan")){
            Toast.makeText(getApplicationContext(), "correct",Toast.LENGTH_LONG).show();
        } else
            Toast.makeText(getApplicationContext(), "incorrect",Toast.LENGTH_LONG).show();
    }
});
</code></pre>
