1

I've 2 activities, Activity1 and Activity2.

In Activity1 i've a EdiText and ImageView. When button is clicked Activity2 is started.

In Activity2 i've a listview. It contains Image and TextView.

I have displayed the data retrieved from listview image and textview in Activity2 in the imageview and editext resp in Activity1 . Now i made some changes in the editext and imageview in Activity1 and I need to pass this changes again to the listview image and text in Activity 2.

can someone help me with the code to make this work?

Lokesh
  • 5,180
  • 4
  • 27
  • 42
  • Now, you have stated what you need. Please show some releavant code you have been working on. It could help us who are trying to help you. – Augustus Francis Sep 23 '13 at 11:21

2 Answers2

1

Better idea is to use startActivityForResult.

It similar problem to this: How to manage `startActivityForResult` on Android?

Community
  • 1
  • 1
TommyNecessary
  • 1,377
  • 1
  • 13
  • 19
0

In your current activity1, create an intent

Intent i = new Intent(getApplicationContext(), Activity2.class);
i.putExtra(key, value);
startActivity(i);

then in the other activity2, retrieve those values.

Bundle extras = getIntent().getExtras(); 
if(extras !=null) {
    String value = extras.getString(key);
}
Lokesh
  • 5,180
  • 4
  • 27
  • 42