This is a migrated thread and some comments may be shown as answers.

Kendo Mobile Sample with InAppBrowser

4 Answers 70 Views
General Discussion
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Mike
Top achievements
Rank 1
Mike asked on 28 May 2014, 08:52 PM
In AppBuilder, I've created a Cordova app that uses InAppBrowser and executeScript and it works fine.  It loads the page I tell it to and it executes the script.

If I take the default kendo mobile app and add the InAppBrowser, it will navigate to the page that I specify, but executeScript will not work.  

Replace the login.js file with the one I have attached.  You will notice a new 'run' function and then a call to that function after the viewModel is instantiated.  


If I remove the run function and use a local variable after the viewModel is instantiated it does work.  I would like to reuse the reference in my model though.

What am I doing wrong here?  

4 Answers, 1 is accepted

Sort by
0
Kaloyan
Telerik team
answered on 31 May 2014, 12:33 PM
Hi Mike,

Please, check if the provided by me reply to your support ticket solves the issue. If so, I will be happy to post it here, as a reference for the community.

Thank you.

Regards,
Kaloyan
Telerik
 

Share what you think about AppBuilder and Telerik Platform with us in our feedback portal, so we can become even better!

 
0
Mike
Top achievements
Rank 1
answered on 03 Jun 2014, 03:01 PM
I did resolve the issue.
0
Mike
Top achievements
Rank 1
answered on 03 Jun 2014, 05:22 PM
What I meant to say is yes it did resolve the issue.  
0
Kaloyan
Telerik team
answered on 04 Jun 2014, 01:58 PM
Hi Mike,

I am glad to hear this.

Here is a reference to our support communication:
"It appears to be an issue only in the AppBuilder simulator as on devices (iOS and Android) the application works as expected and the alert "hi" massage appears. However, note that sometimes, due to the fact your call to the run function is being made before the device is ready, this does not work. To fix this, I moved the execution of the following line after the deviceReady event:
Copy Code
app.loginService.viewModel.run();

Copy Code

However, the issue in the simulator appears to be a security issue inside the Chrome browser. We will further investigate it on our side and will try to provide a fix for it for future AppBuilder releases.
"

Regards,
Kaloyan
Telerik
 

Share what you think about AppBuilder and Telerik Platform with us in our feedback portal, so we can become even better!

 
Tags
General Discussion
Asked by
Mike
Top achievements
Rank 1
Answers by
Kaloyan
Telerik team
Mike
Top achievements
Rank 1
Share this question
or