I'm using, essentially, a variation of the exact same code that everyone else is using since startActivityForResult is deprecated:
ActivityResultLauncher<Intent> ucropActivityIntent = registerForActivityResult(
new ActivityResultContracts.StartActivityForResult(),
new ActivityResultCallback<ActivityResult>() {
public void onActivityResult(ActivityResult result) {
if (result.getData() != null) {
Uri uri = UCrop.getOutput(result.getData());
startCropActivity(uri);
}
}
});
This loads the image picker and I choose my image, but as soon as I've picked the photo it takes me to the Activity where it throws the error: "Both input and OutPut URI Must Be Specified."
If I switch back to...
startActivityForResult(intent, 1);
...instead of:
ucropActivityIntent.launch(intent);
...it works just fine.
Don't know why it's working for everyone else but not for me.
I'm using, essentially, a variation of the exact same code that everyone else is using since startActivityForResult is deprecated:
This loads the image picker and I choose my image, but as soon as I've picked the photo it takes me to the Activity where it throws the error: "Both input and OutPut URI Must Be Specified."
If I switch back to...
startActivityForResult(intent, 1);
...instead of:
ucropActivityIntent.launch(intent);
...it works just fine.
Don't know why it's working for everyone else but not for me.
Here's my startCropActivity: