09-11-2012 07:19 PM
I'm writing an HTML/JavaScript app and would like to port it to the Playbook. My first question is how to replicate making a call to window.open(url) to open a web page on the Playbook.
I would also like to know how to gain access to blackberry.system in my JavaScript code. Is this just automatically available when my app is run on the Playbook? I could test these things much more easily if I had an actual Playbook, but alas I do not. So I shall ask here ![]()
Thanks.
Solved! Go to Solution.
09-12-2012 04:17 AM
Hi jmtk,
1) You could try using the Invoke API:
function openWebLinkInBrowser() {
// open web link in browser
blackberry.invoke.invoke({
target: "sys.browser",
uri: "http://www.blackberry.com"
}, onInvokeSuccess, onInvokeError);
}
2) You need to change the app's configuration file and add the appropriate permitions.
Cheers!
09-12-2012 09:32 AM