Hello


I am using voice recognition on a mobile app (android) version 11.


Below is a screenshot from my code. 


When I run this it is my expectation that  when it gets to the "requestPermission2" action, my device will display a pop up so that the user can give permission? Yet. this does not happen. It goes straight into the Voice recognition permission denied message with error code 2 and success = false. 


Why is this happening? How can I get permission from the device?


Thanks so much!


Vonnelize

An advice first of all, is to put this question in the component itself, so that you can get help faster from those who developed the component.


Yes, I have looked at the example and I am doing exactly the same. This is the example code from the example app and it uses the request Permission in the same way than I am using it.


I have also generated and installed a new apk and that did not solve the issue either.



Hi Vonnelize,

I answered this on your other post

You never check if speech recognition is available. For that use "isRecognitionAvailable" action. 

I checked the component and the ErrorCode 2 is "Speech Recognition is unavailable"

Regards,

Marcelo

Hi Marcelo


Sorry about the two posts.  Nuno said I must create another one.


This is what I have now - see the screen shot. The outcome of isRecognitionAvailable is always false and it shows the message.


My question is, how do I make it available and how do I get the mobile device to give the popup so that the user can give permission?


This used to work the way I had it prior to the latest server version upgrade. I have republished all the modules, regenerated the apk and re-installed the app since the upgrade, but something is still not right.




Hi,

How are you testing the application? For example on Outsystems Now looks like it doesn't work. But when I install the application on my phone everything works fine.

Regards,

Marcelo

I generated an apk on the Native Platform tab. I then scanned the QR code with my phone and installed the apk on my phone. I test the voice recognition and it does not work.


I am not using OutSystems now.

Did you try it in other devices? your device meets the requirements?


Regards,

Marcelo

Hi Marcelo

I have 2 tablets: A and B

And two different apps using voice recognition from two different apps, call them X and Y.


App X works on tablet A but not tablet B.

App Y works on both tablets.


So, in summary, the app that  am struggling with works on another  tablet, but not this one.

Another app, using the same voice recognition functionlity, works on the tablet that my app is not working on.


So, I know there is nothing wrong with the tablet. I also know the code works on another tablet. 


So I am no closer to an answer. It must be something very silly that I am missing.


Vonnelize


The application was already in your phone before adding this new functionality? Because if that is the case you need to install it again because Outystems deployment of the code to the device doesn't include the plugins.

Even if that is not the case maybe re-install could work.

Regards,

Marcelo

Hi Marcelo


I really appreciate you trying to help.


Yes, the application was previously installed. I uninstalled it many times already. I regenerated the app on the native tab, scanned the new qr code with my phone and re-installed it quite a few times already. It does not solve the problem.


Vonnelize

I have now installed the app on a another phone that has never had the application before. I have a button that only has the following and it only returns false, error 2. So, it is not the tablet or the phone but something inside the app?


Hi Vonnelize,

Unfortunately I'm out of ideas. I will try to contact Miguel (component creator) to check if he can help you.

Regards,

Marcelo


Hi Vonnelize,

Like Nuno mentioned, creating a topic on the Component's support page and continuing the discussion there will improve overall visibility. I'm going to close this topic now, post a link to it in your other topic (so no one misses out on what was already explained/discussed here) and suggest a few other things to try and troubleshoot your problem.