last day (14 days later) » 

7:16 AM
0
Q: Android onactivityresult() not being called in fragment

MadhavThis is my code for calling onactivity result. I am using a dialog which prompts to pick image from gallery or from camera. The same code is working in activity but is not working in fragments. I have tried all the previous answers on stackoverflow. Please help AlertDialog.Builder builder = new ...

 
I have tried ur code and its working perfectly to me. Where you have written this code, in fragment only right?
 
yes in the fragment only
 
I have used ur alertbox in oncreateview and checked. It is working perfectly. You can post the code of fragment
 
i have written the code in fragment.. the dialog appears, but when i select a photo from gallery, the image does not set on the imageview.
 
Image is not setting is different issue right. U said onactiivtyresult is not called.
 
7:16 AM
image is setting in onactivityresult and it isnt getting called. I have checked it
 
Just keep log statement and print requestcode in onactivitresult of activity and fragment.
 
where do i write onactivityresult?? in fragment or activity
 
Both the places, In activity and fragment, override onActivityResult method and Just keep log statment
 
ohk i will try
thanx for your help
 
It worked...?
 
7:27 AM
trying
still not working :(
actually the problem is i am having nested fragments
 
U can have a sample project in any location. so that it will be easy to find the problem
 
where do i post it
 
github or google/sites or zip and share in rapidshare/...
 
the code is working in the parent fragment... but not in the child fragment
:D
 
If ur problem is solved..cool
 

last day (14 days later) »