Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Trying to use ZXing barcode scanner in a Forms app: getting error about startActivity()?

$
0
0

I'm trying to invoke the barcode scanner in a command bound to a button, and I'm getting runtime errors referencing:
android.util.AndroidRuntimeException: Calling startActivity() from outside of an Activity context requires the FLAG_ACTIVITY_NEW_TASK flag. Is this really what you want?

I should be inside an activity, so I'm not sure why I would be getting this: could it have anything to do with the command being bound as opposed to a direct click event handler?

EDIT: Nope, just replaced the command binding with an event handler, same error.


Viewing all articles
Browse latest Browse all 58056

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>