how to build intent in activity and receive from fragment

view full story

http://stackoverflow.com – i am new to Android. Is what i am trying to do is stupid? I have build an intent in an activity (EditPhoto) as follows: //Defining intent for loading image to the edit page Intent recentPhoto = new Intent(this, ImportPhoto.class); //Defining byte stream of image chosen ByteArrayOutputStream bs = new ByteArrayOutputStream(); bm.compress(Bitmap.CompressFormat.PNG, 50, bs); //Transforming image to EditPhoto class in byte stream recentPhoto.putExtra("byteArray", bs.toByteArray()); //Starting the in (HowTos)