You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 15, 2024. It is now read-only.
when using MediaPicker.CapturePhotoAsync(); get error "Object reference not set to an instance of an object"
I got this error when testing on Android.
Steps to Reproduce
var result = await MediaPicker.CapturePhotoAsync();
var stream = await result.OpenReadAsync();
imgDocImage.Source = ImageSource.FromStream(() => stream);
just when running first line after shot the photo on phone gets the error : "Object reference not set to an instance of an object"
on the first line, I mean before get a value in "result".
On my OnePlus 5T (Android 10). After capturing a photo I get a shot of it with three options at the bottom: Retake, Approve, and Cancel. Clicking Retake or Cancel does what it should without any issues. However, clicking the check box for approval results in a null reference exception that I suspect is outside of my code's scope as it never hits my catch statement.
I suspect that perhaps there is a missing handler or listener for that type of workflow? CaptureVideo works fine, but as I recall videos don't provide a preview of what you just took in order for you to approve/discard what you captured.
Description
when using MediaPicker.CapturePhotoAsync(); get error "Object reference not set to an instance of an object"
I got this error when testing on Android.
Steps to Reproduce
just when running first line after shot the photo on phone gets the error : "Object reference not set to an instance of an object"
on the first line, I mean before get a value in "result".
Test on Xiaomi note 9 (Android 10)
Expected Behavior
Actual Behavior
Basic Information
Version with issue: 1.6.0 pre2
Last known good version:
IDE: Visual Studio 2019
Platform Target Frameworks:
Android Support Library Version:
Nuget Packages: Xamarin.Essentials 1.6.0-pre2
Affected Devices: Xiaomi Redmi note 9 (Android 10)
Screenshots
Reproduction Link
The text was updated successfully, but these errors were encountered: