Hi Team,
We are in the process of upgrading our mobile application to the latest MABS version (MABS 11.1). During the upgrade, we encountered an error indicating that the InAppBrowser plugin also needs to be updated.
We proceeded to upgrade the InAppBrowser to the latest version and successfully generated the mobile application using MABS 11.1.
Our mobile app includes a functionality where the InAppBrowser is launched based on a specific condition and is automatically closed once the condition is met. This functionality was working as expected until we upgraded to the latest InAppBrowser version, which no longer provides the "Open" action. Instead, it now offers the "OpenInWebView" action.
As a workaround, we used the "OpenInWebView" action and implemented a countdown timer to automatically close the InAppBrowser once the timer ends. However, we are now encountering the following error when triggering the Close action:
"There's no browser view to close."
Could anyone please assist us in implementing the automatic close functionality using the latest InAppBrowser version?
Hi there!
Could you show us how you're implementing your use case? You should be able to close the WebView by simply calling the Open action.
You can do it like this, using a timer in a JavaScript block:
Hi Alexandre,
Thank you for your response to my query.
We were calling the "OpenInWebView" action in the "OnAfterFetch" event. For the timer, we had included a countdown block that triggers an event once the timer completes.
In the timer completed event, we were calling the "Close" action, but it was returning the error OS-PLUG-IABP-0012.
However, based on your suggestion, we implemented the "setTimeout" function using JavaScript, and it's now working fine.
Thank you so much!
Hi Nikhil,
No worries, I'm glad you were able to get it working!