Results 1 to 5 of 5
  1.    #1  
    Hi
    I'm new to web applications.
    I'm following the O'Reilly Palm WebOS book and I cannot get the version in Chapter 2 to run. I just get the grey card trying to load in the emulator, but the stage is not pushed.
    How do I debug this problem. I've checked all of the components and all I can find in Eclipse is that it says /usr/palm/frameworks/mojo/mojo.jsjsjs $is$ $not$ $resolvable$.

    Can anyone explain to me what is happening, and how to resolve the issue?
    Thanks
  2. #2  
    Hi there,
    I don't have the O'Reilly book so I'm not quite sure what you're referring to exactly.
    1) Does your emulator work at all for any other things? Can you launch any of the builtin apps in the emulator?
    2) I'm assuming you have built a basic app according to Chapter 2 and when you try to launch the app in the emulator, all you get is a grey card? If so, this could be due to many possible reasons, even as simple as a single typo somewhere in your code.
    3) Have you checked that your sources.json file contains all the necessary info? At the very least your sources.json file should look like this...
    Code:
    [
        {"source": "app\/assistants\/stage-assistant.jsjsjs&$quot$;},
        {
            &$quot$;$source$&$quot$;: &$quot$;$app$\/$assistants$\/$home$-$assistant$.$js$&$quot$;,
            &$quot$;$scenes$&$quot$;: &$quot$;$home$&$quot$;
        }
    ]
    In the above code, you would replace the word "home" and "home-assistant.jsjsjs&$quot$; $with$ $the$ $correct$ $name$ $of$ $the$ $files$ $you$ $are$ $using$.
    4) You might want to instead try to create the Hello World sample on Palm's website. Once you get that working properly, you'll understand WebOS alot more, and then you might all of a sudden realize what is wrong with your current app. Go here to try Hello World...
    Building Your First App – HP Palm Developer Center
    Developer of: FFplayer - a file/folder based music player. FFplayer home
  3. #3  
    In addition to the previous post, even a single missing } or other character can prevent the scene from being pushed. I'd recommend running the palm-log command (or the stand alone Ares Palm-Log site) to and post the specific error it gives. (I'd also recommend doing a quick read through my tutorial on debugging via the log.)

    You can easily check for syntax errors via JSLint as well. You can load the project in Ares as well to run JSLint.
    Richard Neff

    My tutorials on WebOS development: Beyond 'Hello World!' | Getting Started - WebOS Development

    My apps: Percent Table | SierraPapa
  4.    #4  
    Hello RealMayo and RickNeff
    Thank you for replying to my post.
    I have created the Hello World sample and several other samples successfully.
    I am grateful for your pointing me towards your debugging article in order to use Ares and JSLint.
    Using this information, I have found the reason, which was to add a reference to the location of the feeds.jsjsjs $class$ $file$ $in$ $the$ $sources$.$json$ $file$. $The$ $book$ $instructed$ $me$ $to$ $put$ $the$ $feeds$.$js$ $in$ $the$ $apps$/$models$ $folder$ $and$ $did$ $not$ $mention$ $adding$ $the$ $reference$ $to$ $sources$.$json$ $and$ $I$ $therefore$ $thought$ $that$ $that$ $the$ $folder$ $structure$ $would$ $indicate$ $its$ $location$. $I$ $now$ $know$ $otherwise$!
    In fact Ares did not put feeds.jsjsjs $in$ $a$ /$models$ $folder$ $so$ $I$ $had$ $to$ $work$ $out$ $how$ $to$ $reference$ $it$.
    So, many thanks for your help.
  5. #5  
    Glad to hear you solved it! The O'Reily book is dated and does have some errors. Just be aware of that as you progress through it.
    Richard Neff

    My tutorials on WebOS development: Beyond 'Hello World!' | Getting Started - WebOS Development

    My apps: Percent Table | SierraPapa

Tags for this Thread

Posting Permissions