Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App crashes on creating new instance of ImageCropper #38

Open
ederjbezerra opened this issue Jul 29, 2020 · 9 comments
Open

App crashes on creating new instance of ImageCropper #38

ederjbezerra opened this issue Jul 29, 2020 · 9 comments

Comments

@ederjbezerra
Copy link

When calling

new ImageCropper() { PageTitle = "Cut an image", AspectRatioX = 1, AspectRatioY = 1, CropShape = ImageCropper.CropShapeType.Rectangle, SelectSourceTitle = "Select a file", TakePhotoTitle = "Take a picture", PhotoLibraryTitle = "Pic gallery", Success = (imageFile) => { Device.BeginInvokeOnMainThread(() => { imageView.Source = ImageSource.FromFile(imageFile); }); } }.Show(this);

This exception is threw:

Method not found: System.Threading.Tasks.Task`1<Plugin.Media.Abstractions.MediaFile> Plugin.Media.Abstractions.IMedia.TakePhotoAsync(Plugin.Media.Abstractions.StoreCameraMediaOptions)

ImageCropper 1.0.6
Xam.Plugin.Media 5.0.1
Xamarin.Android.Support.* 28.0.0.3
Xamarin.Essentials 1.5.4.2
Xamarin.Forms 4.7.0.1080

@krunal66nizama
Copy link

having same issue

@ederjbezerra
Copy link
Author

@krunal66nizama fixed only by installing ImageCropper.Forms.Fix on nuget

@krunal66nizama
Copy link

@ederjbezerra thanks

@ershovd
Copy link

ershovd commented Aug 12, 2020

I also have the same issue, have tried ImageCropper.Forms.Fix nuget but it didn't help. any ideas on how to fix this?

@eyeveye
Copy link

eyeveye commented Aug 19, 2020

Having the same issue. Installing ImageCropper.Forms.Fix on nuget doesnt fix. Any idea?

@krunal66nizama
Copy link

try this nuget
ImageCropper.Forms.Fix.v3
link : https://www.nuget.org/packages/ImageCropper.Forms.Fix.v3/

@eyeveye
Copy link

eyeveye commented Aug 20, 2020

try this nuget
ImageCropper.Forms.Fix.v3
link : https://www.nuget.org/packages/ImageCropper.Forms.Fix.v3/

This package even get the "Permission" package typo:

All Frameworks
Plugin.Persmissions (>= 6.0.1)
Xam.Plugin.Media (>= 5.0.1)
Xamarin.Forms (>= 4.6.0)

@krunal66nizama
Copy link

try this nuget
ImageCropper.Forms.Fix.v3
link : https://www.nuget.org/packages/ImageCropper.Forms.Fix.v3/

This package even get the "Permission" package typo:

All Frameworks
Plugin.Persmissions (>= 6.0.1)
Xam.Plugin.Media (>= 5.0.1)
Xamarin.Forms (>= 4.6.0)

download project from that git , and run that code , it will work in android , but still circular crop will not work

@ederjbezerra
Copy link
Author

try this nuget
ImageCropper.Forms.Fix.v3
link : https://www.nuget.org/packages/ImageCropper.Forms.Fix.v3/

This package even get the "Permission" package typo:
All Frameworks
Plugin.Persmissions (>= 6.0.1)
Xam.Plugin.Media (>= 5.0.1)
Xamarin.Forms (>= 4.6.0)

download project from that git , and run that code , it will work in android , but still circular crop will not work

Unable to find package Plugin.Persmissions. No packages exist with this id in source(s): nuget.org

I think the problem is Permissions was wrote wrong. I have Plugin.Permissions installed but can't install ImageCropper because it expects Plugin.Persmissions. How can I solve that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants