admin管理员组

文章数量:1318573

I'm using the image_picker package in my Flutter app to take photos and pick files. However, I'm facing two issues:

Camera Issue:

When taking a photo with the camera, the photo is taken, and I confirm the selection, but nothing happens afterward (no callback, no image displayed, etc.).

File Picker Issue:

When picking a file, the file is picked correctly. However, upon returning to the app, nothing happens (no callback, no image displayed). When trying to open the file picker again, I get the following error: Unhandled Exception: PlatformException(already_active, Image picker is already active, null, null)

What I've Tried:

1 : Ensured all permissions are added in both AndroidManifest.xml and Info.plist. 2 : Used the latest version of the image_picker package (image_picker: ^1.1.2). 3 : Made sure to await the pickImage method. 4 : Handled null values from the pickImage method. 5 : Checked for activity conflicts and ensured the picker isn't triggered multiple times.

本文标签: