Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/109.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Phonegap iOS中的Scandit条形码扫描仪问题_Ios_Cordova_Barcode_Barcode Scanner - Fatal编程技术网

Phonegap iOS中的Scandit条形码扫描仪问题

Phonegap iOS中的Scandit条形码扫描仪问题,ios,cordova,barcode,barcode-scanner,Ios,Cordova,Barcode,Barcode Scanner,我在Phonegap中使用Scandit条形码扫描仪。我正在创建一个iOS应用程序 我已经成功地将扫描仪安装到我的应用程序中,在我扫描二维码之前一切都很好,它振动了,但没有显示我扫描的二维码页面,它只是返回到我的应用程序 (我在这里学习了教程:) 我能知道如何解决这个问题吗?这是我在html中为扫描仪编写的脚本 <script type="text/javascript"> function onBodyLoad() { document.ad

我在Phonegap中使用Scandit条形码扫描仪。我正在创建一个iOS应用程序

我已经成功地将扫描仪安装到我的应用程序中,在我扫描二维码之前一切都很好,它振动了,但没有显示我扫描的二维码页面,它只是返回到我的应用程序

(我在这里学习了教程:)

我能知道如何解决这个问题吗?这是我在html中为扫描仪编写的脚本

    <script type="text/javascript">
    function onBodyLoad()
    {
        document.addEventListener("deviceready", onDeviceReady, false);
    }

function success(concatResult) {
    resultArray = concatResult.split("|");
    alert("Scanned " + resultArray[0] + " code: " + resultArray[1]);
}

function failure(error) {
    alert("Failed: " + error);
}

function scan() {
    // See ScanditSDK.h for more available options.
    cordova.exec(success, failure, "ScanditSDK", "scan",
                 ["kI0HjHANEeOZZ+IFvIjVQ1D5+g0sVUMkiAEQdYKlCMI",
                  {"beep": true,
                  "1DScanning" : true,
                  "2DScanning" : true,
                  "qr" : true,
                  "scanningHotspot" : "0.5/0.5",
                  "vibrate" : true,
                  "textForInitialScanScreenState" :
                  "Align code with box",
                  "textForBarcodePresenceDetected" :
                  "Align code and hold still",
                  "textForBarcodeDecodingInProgress" : "Decoding",
                  "searchBarActionButtonCaption" : "Go",
                  "searchBarCancelButtonCaption" : "Cancel",
                  "searchBarPlaceholderText" :
                  "Scan barcode or enter it here",
                  "toolBarButtonCaption" : "Cancel",
                  "minSearchBarBarcodeLength" : 8,
                  "maxSearchBarBarcodeLength" : 15}]);

}

app.initialize();
    </script>

函数onBodyLoad()
{
文件。添加的监听器(“deviceready”,OnDeviceraddy,false);
}
函数成功(concatResult){
resultArray=concatResult.split(“|”);
警报(“已扫描”+resultArray[0]+“代码:+resultArray[1]);
}
功能故障(错误){
警报(“失败:+错误”);
}
函数扫描(){
//有关更多可用选项,请参见ScanditSDK.h。
cordova.exec(成功,失败,“ScanditSDK”,“扫描”,
[“kI0HjHANEeOZZ+IFvIjVQ1D5+g0sVUMkiAEQdYKlCMI”,
{“哔”一声:没错,
“1D扫描”:是的,
“二维扫描”:对,
“qr”:正确,
“扫描热点”:“0.5/0.5”,
“振动”:没错,
“textForInitialScanScreenState”:
“将代码与框对齐”,
“检测到TextForBarCodePresence”:
“对齐代码并保持静止”,
“textForBarcodeDecodingInProgress”:“解码”,
“SearchBarActionButton选项”:“开始”,
“SearchBarCancelButton选项”:“取消”,
“搜索栏占位符文本”:
“扫描条形码或在此处输入”,
“工具栏按钮选项”:“取消”,
“MinSearchCodeLength”:8,
“maxSearchCodeLength”:15});
}
app.initialize();