You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
i dunno why but i have this "main loop exeption" with an alert when i run the feature please help me
This is my code:
if (/Android/i.test(navigator.userAgent)) {
navigator.camera.getPicture(onSuccess, onFail, {
quality: 100,
destinationType: Camera.DestinationType.DATA_URL ,
sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
correctOrientation: true,
});
function onSuccess(imageData) {
var image = document.getElementById('render');
image.src = "data:image/jpeg;base64," + imageData;
image.style.display = "flex";
prinscatta.style.display = "none";
textocr.recText(4,imageData,onSuccess,onFail);
function onSuccess(recognizedText)
{
testoiniziale2 = recognizedText;
console.log(testoiniziale2);
boxtraduzione2.value = recognizedText;
alert(recognizedText);
}
function onFail(message)
{
alert(message);
}
}
i dunno why but i have this "main loop exeption" with an alert when i run the feature please help me
This is my code:
if (/Android/i.test(navigator.userAgent)) {
navigator.camera.getPicture(onSuccess, onFail, {
quality: 100,
destinationType: Camera.DestinationType.DATA_URL ,
sourceType: Camera.PictureSourceType.PHOTOLIBRARY,
correctOrientation: true,
});
function onSuccess(imageData) {
var image = document.getElementById('render');
image.src = "data:image/jpeg;base64," + imageData;
image.style.display = "flex";
prinscatta.style.display = "none";
textocr.recText(4,imageData,onSuccess,onFail);
function onSuccess(recognizedText)
{
testoiniziale2 = recognizedText;
console.log(testoiniziale2);
boxtraduzione2.value = recognizedText;
alert(recognizedText);
}
function onFail(message)
{
alert(message);
}
}
function onFail(message) {
window.plugins.toast.showWithOptions(
{
message: message,
duration: "short",
position: "bottom"
}
);
}
The text was updated successfully, but these errors were encountered: