title: The constructor Intent(new View.OnClickListener(){}, Class<DrinksTwitter>) is undefined
body: <p>I am getting the following error:</p>
  
  <pre><code>The constructor Intent(new View.OnClickListener(){}, 
                         Class&lt;DrinksTwitter&gt;) is undefined
  </code></pre>
  
  <p>In the following code snippet:</p>
  
  <pre><code>@Override
  public void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.main);
  
      // Get the EditText and Button References
      etUsername = (EditText)findViewById(R.id.username);
      etPassword = (EditText)findViewById(R.id.password);
      btnLogin = (Button)findViewById(R.id.login_button);
      btnSignUp = (Button)findViewById(R.id.signup_button);
      lblResult = (TextView)findViewById(R.id.result);
  
      // Set Click Listener
      btnLogin.setOnClickListener(new OnClickListener() {
          @Override
          public void onClick(View v) {
              // Check Login
              String username = etUsername.getText().toString();
              String password = etPassword.getText().toString();
  
  
              if(username.equals("test") &amp;&amp; password.equals("test")){
                  final Intent i = new Intent(this, DrinksTwitter.class);  //error on this line
                  startActivity(i);
                  // lblResult.setText("Login successful.");
                  } else {
                  lblResult.setText("Invalid username or password.");
              }
          }
      });
  
      final Intent k = new Intent(Screen2.this, SignUp.class);
  
      btnSignUp.setOnClickListener(new OnClickListener() {
  
          public void onClick(View v) {
  
              startActivity(k);
          }
      });
  
  }
  </code></pre>
  
  <p>What am I doing wrong with the line:</p>
  
  <pre><code>final Intent i = new Intent(this, DrinksTwitter.class); 
  </code></pre>