//fetching extra data passed with intents in a Bundle type variable
extras = getIntent().getExtras();
if(extras == null)
{ newString= null;
}
else
{ /* fetching the string passed with intent using ‘extras’*/
newString= extras.getString("STRING_I_NEED");
}
}