Filebrowsing PlayBook with Webworks/PhoneGap

I'm pass Air/Actionscript to WebWorks and a bit of trouble. I tried several tutorials browser for the file Phonegap and samples I found on the web, but they do not work on the Playbook. I added the permission to access_shared to the config. I have a

    and when my application starts it's supposed to load the files and directories in the
      .

      My js is below:

      document.addEventListener("deviceready", onDeviceReady, false);
      function onDeviceReady(){
      window.requestFileSystem(
      LocalFileSystem.PERSISTENT,
      0, onFileSystemSuccess, fail
      );
      }
      
      function onFileSystemSuccess(fileSystem) {
      // Create some test files
      fileSystem.root.getDirectory("myDirectory",
      { create: true, exclusive: false },
      null,fail);
      fileSystem.root.getFile("readthis.txt",
      { create: true, exclusive: false },
      null,fail);
      var directoryReader = fileSystem.root.createReader();
      // Get a list of all the entries in the directory
      directoryReader.readEntries(success,fail);
      }
      
      function success(entries) {
      var i;
      var objectType;
      for (i=0; i

      ' + entries[i].name + '

      ' + entries[i].toURI() + '

      Type: ' + objectType + '

      '); } $('#directoryList').listview("refresh"); } function fail(error) { alert("Failed to list directory contents: " + error.code); }

      I found the example Dir in kickensink showed me what I needed to know.

Tags: BlackBerry Developers

Similar Questions

  • Error during construction through ripple for Blackberry Playbook, with WebWorks-Tablet

    Hello

    I am currently working on a blackberry app coded in HTML5.

    I am looking to build for the playbook, following the instructions

    https://developer.BlackBerry.com/HTML5/documentation/creating_helloworld_for_blackberry_playbook.htm...

    However, when building it, I get the following error message

    The first error message is caused by error when loading "jvm.dll" However, I checked, and this file exist in this directory.

    Any help or sugestion would be greatly appreciated!

    Thank you.

    You must use JDK 6, and it must be 32-bit. I use the 32-bit JDK 6u45.

  • Bug in signature tool: PlayBook & BB10 WebWorks signature tools create different ID of Package

    Hello, I wanted to download a version BB10 of a portal provider WebWorks app, but I've always had the

    File bundle (blabla.bar) was rejected. Package ID is required for all .bar file. If this is an upgrade, ID of Package must match ID of Package in the bundle of original file.

    error. I read a lot of articles like this one

    http://devBlog.BlackBerry.com/2012/03/package-ID-rejected-by-app-world/#more-8665

    on this issue, and most of them say, you used a different signing key, or you have changed the name of the Package. However none are the case - really.

    What I found is:

    The latest version of the SDK PlayBook WebWorks 2.2.0.5 produced an another Package ID in the MANIFEST. The latest version of the SDK BB10 WebWorks 1.0.2.9 MF file. I use the latest plugin ripple to package and sign applications.

    If I package sign my application with the SDK BB10 bundle file gets rejected. If I package and sign the exact folder of files (not changed character) with WebWorks PlayBook the supplier portal SDK allows me to download the bar.

    When I checked both the MANIFESTO. MF, package-Ids files were indeed different. However this way, you can provide a free upgrade for your existing PlayBook application for BB10 platform.

    Here's your solution, 3rd post http://supportforums.blackberry.com/t5/Web-and-WebWorks-Development/How-to-set-up-Package-Name-for-P...

    It is good that we can specify the name of the package in bb10 sdk.

  • Custom BB Webworks/Phonegap plugin for BB10

    Hello

    Can you please help me how to write Custom BB Webworks/Phonegap plugin for BB10? I knew for BB Java Smartphone (phonegap plugins).

    Hello

    We are working on the construction of full support for plugins to cordova, but for now, you must create a WebWorks extension and import it on the folder your PhoneGap project www.

    Here is a model to help you get started:

    https://github.com/BlackBerry/WebWorks-community-APIs/tree/master/BB10/template

  • Y at - it an IDE that can make the AutoComplete with webworks - 1.0.2.9.js?

    Y at - it an IDE that can make the AutoComplete with webworks - 1.0.2.9.js?

    I tried with Visual Studio 2010 and 2012, but the two do not have an AutoComplete. Or I'm doing it wrong.

    Try Aptana Studio 3

    http://www.Aptana.com/

  • Problem signature App Playbook with ripple

    I am signing my app playbook with ripple. I use version 2.2.0.5 of the tablet OS SDK.
    I downloaded signature keys and installed them. I was able to generate a signed application.

    However, the second time that I tried to build an application signed, I get the below error. All subsequent attempts to sign the app failed with the same error. The only change that I did between the first and the second was to activate my wireless router I have compiled and signed application push on my test device Playbook automatically via wifi using ripple. I don't see how this would have caused an error like the one below, however. Also, I know that the passwords that I am providing are correct.

    A that someone has had this problem and solved?

    Message: "Oh Snap!" Build request failed with the message: signature [ERROR] failed to the signature on the signature application didn't check the code. The probable cause of this problem is entered a wrong password CSK. »

    To confirm that the password is not really the problem, you can try not to build your application from the command line?

    https://bdsc.webapps.BlackBerry.com/HTML5/documentation/ww_publishing/signing_your_tablet_app_191966...

    You have all non-alphanumeric characters in your password - as a single or double quote?

  • How to get started developing applications with Webworks

    Hi all!

    So I have an idea to build an HTML5 app for use by the Office on BES10. Basically it digitizes a 2 page paper form to be used on a device (PlayBook or Android) taking advantage of the function of swipping and scrolling of screen minimizing

    Here are the details:

    (1) the office worker: take Excel data and partially fills a form (or multiple shapes - similar to mail merge) to a specific area coordinator.

    (2) the office worker: push forms pre-filled as a coordinator on a PlayBook application or another html5 client connected to BES10 (private App)

    (3) Coordinator: logs in-App to 'their space '.

    (4) Coordinator: filling out form and supports (or partially fill in form to submit later).

    (5) time stamp is applied to participate "forms" submitted.

    (6) field coordinator: can view their history of completed forms (read-only)

    (7) the office worker: can view, print, save, or extract data from forms.

    How I started with this project? I have to go back and take a class HTML5 then a webworks courses?

    Thanks for your comments.

    Hello

    When you think Webworks is a framework that relies on HTML5, CSS and JavaScript for its applications.

    So if you are looking to develop an application, with a background in HTML5, JavaScript and CSS is certainly recommended and would be the best starting point that I can recommend.

    In your case, it seems that it would also be a bit of work on the backbone (to store data on a server) for which I highly recommend looking in Node.js + Express.js (for the web server) and MySQL for any back-end storage.

    WebWorks which gives you on top of that is a subset of the JavaScript APIs specific BlackBerry that allows you to take advantage of the native features (Toast messages, Push Services, etc.)
    https://developer.BlackBerry.com/HTML5/APIs/v2_1/

    However the structure underlying and functionality is always HTML5, JavaScript and CSS.

    Once your application is HTML5 writes, and you have chosen to use / not use WebWorks APIs, you can then use WebWorks to 'package' for your project of HTML5 in a file that runs on BlackBerry 10 devices.

    The app itself is so standard web technology, with the ability to use native APIs via WebWorks. And WebWorks place it in a container that can be run on a physical device.

    For PlayBook, it's the best starting point:
    https://developer.BlackBerry.com/PlayBook/HTML5/

  • Force landscape mode with WebWorks

    To force a mode application landscape, the following should be added to in your *-app.xml file:

    fake

    landscape

    If I create one *-app.xml for my WebWorks project, however, it is ignored by the compiler. So far, I've been open my .bar file after compilation, extract the *-app.xml the compiler creates, edit and update the archive, but I suspect that this will not be an option when the time comes to sign my applications.

    What other options do I have?

    Hello world

    We have actually had discussions about this feature today... We look at a few solutions that would be built into the software.

    For the moment, you can try the following... (I have not tested it yet)

    If you go into the "bbwp\AirAppTemplates\src" directory where you installed the WebWorks for PlayBook SDK you'll find a file called WebWorksAppTemplate - App.xml

    I think it's the file use us as a model and then replace specific fields with the information from your config.xml file.

    Try to make changes to this file, and they can stick to you.  Also note that the changes here will affect all of the apps you build with the SDK.

  • Name of the company signature PlayBook with a comma

    I am signing an app webworks for the playbook, and when I ran this:

    . / blackberry-keytool - genkeypair - keystore sigtool.p12 - storepass mypassword - dname "cn = Creative App Design, LLC" - author alias

    I got this error:

    keytool error: java.io.IOException: format Incorrect AVA

    The only way I have found to work around this problem is to enter the name of the enterprise without a comma. This allowed everything runs smoothly until I'm actually trying to sign the app, and I get this message:

    barsigner error: Server error: Code signing request has failed because the developer certificate common name is not [Creative Design LLC App].

    The only thing I can think is that when I signed up for signature keys I registered under the name of the company by a comma, so it won't check when I do not use a comma when generating the key. Do I need to re-register for keys under my name of the society without the comma, although this is not what my actual company name?

    This whole process has been an incredible pain...

    You are right.  Punctuation is not allowed in the CN name, and this name should match what was used when registering for the keys.  You will probably need to get a new set of keys with a simpler of the organization name.

  • Android/iOS with WebWorks applications?

    A Blackberry native application developer for a long time, I do the jump-platform with HTML5/CSS/JavaScript. Since WebWorks is essentially implemented Blackberry of Cordova, as long as I didn't use Blackberry own plugins I thought I'd be able to use Webworks to build for Android and iOS in more 10 Blackberry. Unfortunately, I can't add Android WebWorks as target a platform. Now I wonder if WebWorks is able to establish for non-Blackberry platforms or it is locked.

    Can someone tell me if I return to Cordoba or how to add the Android platform to WebWorks, if this is supposed to be possible?

    Thank you.

    I have seen this before when the Android SDK has not been configured correctly.

    Read the guide to the platform and bring attention to environment variables and path parameters that are needed.

    http://Cordova.Apache.org/docs/en/3.3.0/guide_platforms_android_index.MD.html

  • BBUI.js problems with WebWorks 2.0

    Is anyone else having problems with BBUI.js & WebWorks 2.0?

    Like for example the menu tags do not seem to work. There is no evidence that when you drag to the bottom of a simulator.

    Just to doublecheck, what is the master key of the master branch or the branch WebWorks - 2.0 ?

    https://github.com/BlackBerry/BB10-WebWorks-samples/tree/WebWorks-2.0

    In addition to deviceready, have replaced webworks.js with cordova.jsloading?

    The next steps would be to connect Web Inspector and allow the application to load, and then press CTRL + r in the Web Inspector to reload the application and monitor the console to see if there are problems there.

    I take just a few assumptions here because I have not been able to produce this on my machine... my steps were:

    And I can see the interface successfully user and the application to launch.

  • Help with webworks plugin/extension.

    Hi guys, for a few weeks, I decided to love make an app for BB10. I did some research and found that this webworks was the way to go because of my prior knowledge of HTML and JS. I started to design the GUI and a few days back, I was. Then he came to the coding part, and I hit a wall, a huge wall.

    My application is a manager a little bluetooth and I need to give him the possibility to activate bluetooth in-app, but is not possible via webworks (to the best of my knowledge and apparently, my research has not sufficiently thorough). I did research more far and I found that it was possible, but only through the natives(core/cascades). I almost burst into tears because I speak of hours invested in webworks thrown through the windows. I did research more far and found that its possible for access to native code via webworks but will need a plugin/extension. Happy goes me to the site of BB and they have sort tutorial on the subject, but I spent the last 2 days on the site and is not quite explanatory.

    TL; DR... Someone at - it have a plugin/extension for webworks bluetooth or know where I can download one or know where I can find an indept tutorials on how I can make one for me? the model on github no use was more (no comments/explanation)

    Take a look at this project, I wrote:

    https://github.com/BlackBerry/BB10-WebWorks-community-samples/tree/master/SimpleBtSppPlugin

    It is a simplified version of a plugin I wrote recently to support a WebWorks app that interacts with a number of Bluetooth devices (Bluetooth Smart [aka Low Energy] and legacy SPP).

    This simplified version provides a simple JavaScript interface to the Bluetooth SPP (Serial Port Profile), but the model is quite obvious and extensible to any other Bluetooth woud profile you want.

    The API is described here:

    https://github.com/BlackBerry/BB10-WebWorks-community-samples/BLOB/master/SimpleBtSppPlugin/document...

    The associated blog appears in the BlackBerry Developer blog next week and the Plugin will be registered with the Plugin of Cordova register soon as well.

    I'm not an expert WebWorks GUI so forgive the simple sample application which has included :-)

  • How to create the context menu PlayBook under WebWorks

    I searched for hours and I can't find any guidance on how to create a context menu for an application PlayBook WebWorks. I refer the menu which is supposed to appear when you drag to the bottom of the top. I tried to use logical blackberry.ui.menu, but it seems that the functionality of the user interface is not yet available for the PlayBook.

    BlackBerry World, they stressed that it is an important aspect of any application PlayBook so there must be a way to do it. Can someone give me a little push in the right direction?

    -Thanks!

    If you referring to the menu that goes down when a user slips to the bottom of the upper part of the PlayBook, please see this for an example application.

    http://supportforums.BlackBerry.com/T5/Web-and-WebWorks-development/sample-code-swipe-down-menu-for-...

  • BB10 of the Native INTERFACE elements (ActionMenu, AppMenu, TabbedPane) with Webworks

    I have everyone,

    I'm new to BB10 development and I was wondering if there is the possibility to include elements of native user interface as ActionMenu AppMenu, Tabbedpane via Webworks and also invite the recognnition gesture to open these petite (wide top, left kick,...).

    I saw a jQueryMobile app and I want to incorporate some conductive native via Webworks. Without using frames

    as BBUI.js. So is it possible to do with just call some javascript webworks funtions to add an action menu (on the left), tabbedpane (down) and an AppMenu (upwards)?

    Or do I need to include structures such as BBUI.js and adding the recognition of gestures by myself?

    There is no built-in controls to WebWorks. It only contains plain HTML/JS/CSS and the ability to display some simple dialogues. You will need a user interface infrastructure or code your own UI.

    Note: the framework of the BBUI.js and the JQM with BB10 theme are different things. They serve similar objectives, but are not compatible with eachother. Judging by your posts you seem to be mixing up.

    As you already use JQM, I would say just to add the theme JQM BB10.

    Most of the BBUI projects use the Hammer.js framework for gestures. JQM projects, you can use the built-in JQ/JQM events, or choose to use Hammer.js too. Niether of these methods are specific to the BB and should work on any mobile device.

  • Download of images with WebWorks for Tablet

    Hello

    I have some difficulty to find ways to download the images using the JavaScript API. At first, I thought XmlHttpRequest might be the right answer, but it doesn't seem to work with binary data.

    Basically, I need to make a connection to my server which will then return the profile information for that user, including a few images. The server will provide the URL of the images and they will be recovered separately.

    Did someone do something like that? I'm new to JavaScript and have so far found that it is a little strange.

    Thank you

    TL; Dr - how to download images and save them by programming on the Playbook?

    Hi tyler,.

    You can find the best way to do this is to use the upload/download API in our community repo.

Maybe you are looking for