Malik Haseeb
Malik Haseeb

Reputation: 671

When i try to add ZXing.Net.Mobile.forms in xamrin forms and compile then it shows errors

i want to create the barcode reader app, and when i try to add ZXing.Net.Mobile.forms library and compile the code below then it is showing me errors.

MainActivity.xamal.cs `

    private async void Button_Clicked(object sender, EventArgs e)
    {
        var scan = new ZXingScannerPage();
        await Navigation.PushAsync(scan);

        scan.OnScanResult += (result) => { Device.BeginInvokeOnMainThread(async () =>
        {
            await Navigation.PopAsync();
            barcode.Text = result.Text;
        }); };
    }

Errors

When i try to compile the project these erorr are coming`

This is the errors coming when i compile the project

Upvotes: 0

Views: 379

Answers (1)

ottermatic
ottermatic

Reputation: 1012

You should have Zxing.Net.Mobile.Forms installed in all three projects. Android has the additional requirement of needing ZXing.Net.Mobile installed. Install that in your Android project and it should fix your issue.

Upvotes: 3

Related Questions