After adding an object, you need to call one Activity (SizeDialog) twice to enter different parameters. The problem is that after the first call the data comes, and after the second there is no. Here is a simplified code cleared of everything superfluous:
protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); switch (requestCode) { case ACTIVITY_OBJECT: if (resultCode == RESULT_OK) { String selected_object = data.getStringExtra(GoodsListActivity.SELGOOD); addObject(selected_object); Intent intentSize = new Intent(this, SizeDialog.class); intentSize.putExtra("dialog_title", getResources().getString(R.string.object_width)); startActivityForResult(intentSize, ACTIVITY_WIDTH); } break; case ACTIVITY_WIDTH: if (resultCode == RESULT_OK) { int selectedObjectID = objects_list.getCheckedItemPosition(); if (selectedObjectID == -1) { return; } float width_value = data.getFloatExtra(SizeDialog.SIZEVALUE); SetObjectWidth(selectedObjectID, width_value); Intent intentSize = new Intent(this, SizeDialog.class); intentSize.putExtra("dialog_title", getResources().getString(R.string.object_height)); startActivityForResult(intentSize, ACTIVITY_HEIGHT); } break; case ACTIVITY_HEIGHT: if (resultCode == RESULT_OK) { int selectedObjectID = objects_list.getCheckedItemPosition(); if (selectedObjectID == -1) { return; } float height_value = data.getFloatExtra(SizeDialog.SIZEVALUE); SetObjectHeight(selectedObjectID, height_value); } break; } }