Please Help,
whay the result if(Title.toString().trim() == "camera")
is false
?
my code:
mGridView.setOnItemClickListener(new AdapterView.OnItemClickListener() {
public void onItemClick(AdapterView<?> parent, View v, int position, long id) {
//Get item at position
GridMenuItem item = (GridMenuItem) parent.getItemAtPosition(position);
String Title =item.getTitle();
if(Title.toString().trim() == "camera"){
String strPhoneNumber;
Bundle b = getIntent().getExtras();
strPhoneNumber = b.getString("phonenumber");
Intent myIntent = new Intent(v.getContext(), UploadActivity.class);
Bundle bs = new Bundle();
bs.putString("phonenumber", strPhoneNumber); //Your id
myIntent.putExtras(b); //Put your id to your next Intent
startActivityForResult(myIntent, 0);
finish();
}
if(Title.toString() =="history"){
Intent myIntent = new Intent(v.getContext(), HistoryActivity.class);
startActivityForResult(myIntent, 0);
}
if(Title.toString() =="setting"){
Intent myIntent = new Intent(v.getContext(), HistoryActivity.class);
startActivityForResult(myIntent, 0);
}
}
});