I must be doing something wrong. I have this code in the first activity:
package com.Trenton.waziapp; import android.os.Bundle; import android.app.Activity; import android.content.Intent; import android.view.Menu; import android.view.View; import android.view.View.OnClickListener; import android.widget.Button; import android.widget.EditText; public class WaziLoginScreen extends Activity implements OnClickListener{ EditText etUsername, etPassword; Button bLogin; Class ourClass; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.wazi_login_screen); etUsername = (EditText) findViewById(R.id.etUsername); etPassword = (EditText) findViewById(R.id.etPassword); bLogin = (Button) findViewById(R.id.bLogin); } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.wazi_login_screen, menu); return true; } @Override public void onClick(View v) { // TODO Auto-generated method stub switch(v.getId()){ case R.id.bLogin: Intent a = new Intent(WaziLoginScreen.this, ProfileScreen.class); startActivity(a); break; } } } What am I doing wrong here above to get the other Activity, ProfileScreen to open?
My manifest file contains activity entry like this-
<activity android:name=".ProfileScreen" android:label="@string/title_activity_profile_screen"> </activity>