我一直在使用Xamarin和以下选项使用 ZXing .Net 扫描 DataMatrix (标准GS1)。但是仍然无法获得ASCII值(FNC1)。
private async void scanButton_Clicked(object sender, EventArgs e)
{
var options = new ZXing.Mobile.MobileBarcodeScanningOptions
{
PossibleFormats = new List<ZXing.BarcodeFormat>() {
ZXing.BarcodeFormat.DATA_MATRIX
}
};
options.AssumeGS1 = true;
//Scanning part
var barcode = "";
scanPage = new ZXingScannerPage(options);
scanPage.OnScanResult += (result) =>
{
scanPage.IsScanning = false;
Device.BeginInvokeOnMainThread(() =>
{
Navigation.PopAsync();
barcode = result.Text;
});
};
await Navigation.PushAsync(scanPage);
}
为什么我看不到ASCII值(FNC1)?
谢谢