1

Java getIntent.getStringExtra is returning null

view story
linux-howto

http://stackoverflow.com – getIntent keeps returning null and I cannot figure out what the problem is. i used putExtra() which should store the strings, and I am calling it using getIntent.getStringExtra() in another activity. This is the activity with the putExtra() String lati = tvLatitude.getText().toString(); String lng = tvLongitude.getText().toString(); Intent i = new Intent(this, NoteActivity.class); i.putExtra("lati", lati); i.putExtra("lng", lng); This is the activity with getIntent() if (getIntent().getStringExtra("lati") != null && (getIntent().getStringExtra("lng") != null)){ (HowTos)