Skip to content

startActivityForResult doesn't work in fragment ?? #2

@hamed9192

Description

@hamed9192

hi,
your method doesn't work in fragment ??
my code is:
public void onClick(View v) {
try{
startActivityForResult(cameraPhoto.takePhotoIntent(),CAMERA_REQUEST);
cameraPhoto.addToGallery();
} catch(IOException e){
Toast.makeText(getApplicationContext(), "taking photos", Toast.LENGTH_SHORT).show();
}
}
//////////////////////////////////////////////////////////
add getActivity() to startActivityForResult but doesn't work
please guide me,Thank you for your help

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions