Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
New Developer
Posts: 70
Registered: ‎01-13-2011
My Device: Torch 9800 and Playbook
My Carrier: Rogers

Error Compiling the Sample sketchpad Application

Hello I installed the Playbook Simulator and SDK as well as the Air SDK. When I installed the WebWorks sdk it seemed to verify my AIR installation without issue. But now that I'm compiling the sample application i'm getting the following error

 

For reference I'm running WIndows 7. I've tried running the command prompt as a normal user and an admin.

 

 

C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayB
ook\bbwp>bbwp C:\Users\Peter\Downloads\sketchPadStandard\sketchPadStandard.zip
[INFO]                  Parsing command line options
[INFO]                  Parsing bbwp.properties
[INFO]                  Validating WebWorks archive
[INFO]                  Parsing config.xml
[WARNING]               Failed to find a <feature> element
[INFO]                  Populating application source
[INFO]                  Compiling WebWorks application
Error loading: C:\Program Files\Java\jdk1.6.0_18\jre\bin\server\jvm.dll
[INFO]                  Packaging the bar file
java.io.FileNotFoundException: C:\Users\Admin\AppData\Local\Temp\widgetGen.18064
135761294971417022.tmp\sketchPadStandard.swf (The system cannot find the file sp
ecified)
        at java.io.FileInputStream.open(Native Method)
        at java.io.FileInputStream.<init>(Unknown Source)
        at net.rim.tumbler.file.FileManager.copyFile(FileManager.java:473)
        at net.rim.tumbler.airpackager.AirPackager.run(AirPackager.java:126)
        at net.rim.tumbler.WidgetPackager.go(WidgetPackager.java:154)
        at net.rim.tumbler.WidgetPackager.main(WidgetPackager.java:80)
[ERROR]                 Air Packager exception occurred

 

C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp>bbwp C:\Users\Peter\Downloads\sketchPadStandard\sketchPadStandard.zip[INFO]                  Parsing command line options[INFO]                  Parsing bbwp.properties[INFO]                  Validating WebWorks archive[INFO]                  Parsing config.xml[WARNING]               Failed to find a <feature> element[INFO]                  Populating application source[INFO]                  Compiling WebWorks applicationError loading: C:\Program Files\Java\jdk1.6.0_18\jre\bin\server\jvm.dll[INFO]                  Packaging the bar filejava.io.FileNotFoundException: C:\Users\Admin\AppData\Local\Temp\widgetGen.18064135761294971417022.tmp\sketchPadStandard.swf (The system cannot find the file specified)        at java.io.FileInputStream.open(Native Method)        at java.io.FileInputStream.<init>(Unknown Source)        at net.rim.tumbler.file.FileManager.copyFile(FileManager.java:473)        at net.rim.tumbler.airpackager.AirPackager.run(AirPackager.java:126)        at net.rim.tumbler.WidgetPackager.go(WidgetPackager.java:154)        at net.rim.tumbler.WidgetPackager.main(WidgetPackager.java:80)[ERROR]                 Air Packager exception occurred

 

A number of files are placed in that temp directory (widgetGen.18064135761294971417022.tmp) but not the sketchPadStandard.swf 

 

Oddly, that jvm.dll is in the right place.

New Member
Posts: 1
Registered: ‎01-14-2011
My Device: Not Specified

Re: Error Compiling the Sample sketchpad Application

point to the jre bundled with bbwp in your env profile i.e. JAVA_HOME=c:\bbwp\jre and restart cmd

Visitor
Posts: 1
Registered: ‎01-18-2011
My Device: Not Specified

Re: Error Compiling the Sample sketchpad Application

[ Edited ]

I am running into a similar error and have set my JAVA_HOME to the JRE installed with bbwp but still doesn't work.

 

 

C:\Program Files\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp>bbwp "C:\Program Files\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp\sketchPadStandard.zip"
[INFO]                  Parsing command line options
[INFO]                  Parsing bbwp.properties
[INFO]                  Validating WebWorks archive
[INFO]                  Parsing config.xml
[WARNING]               Failed to find a <feature> element
[INFO]                  Populating application source
[INFO]                  Compiling WebWorks application
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\WebWorksAppTemplate.as(172): col: 30 Error: Access of possibly undefined property location through a reference with static type qn
x.events:ExtendedLocationChangeEvent.
                        var urlSmiley Frustratedtring = qnxEvent.location;
                                                  ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\WebWorksAppTemplate.as(26): col: 21 Error: Definition flash.events:LocationChangeEvent could not be found.
        import flash.events.LocationChangeEvent;
                           ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(90): col: 29 Error: Access of undefined property LocationChangeEvent.
                        webView.addEventListener(LocationChangeEvent.LOCATION_CHANGING, locationChanging);
                                                 ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(91): col: 29 Error: Access of undefined property LocationChangeEvent.
                        webView.addEventListener(LocationChangeEvent.LOCATION_CHANGE, locationChanged);
                                                 ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(190): col: 68 Error: Implicit coercion of a value of type qnx.events:ExtendedLocationChangeEvent
to an unrelated type Object.
                        dispatchEvent(new WebkitEvent(WebkitEvent.TAB_LOCATION_CHANGED, event));
                                                                                        ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(197): col: 54 Error: Access of possibly undefined property location through a reference with stat
ic type qnx.events:ExtendedLocationChangeEvent.
                        var access : Access = config.getAccessByUrl(event.location);
                                                                          ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(198): col: 30 Error: Access of possibly undefined property location through a reference with stat
ic type qnx.events:ExtendedLocationChangeEvent.
                        if (access==null && event.location!="about:blank" && !config.getProperty(ConfigConstants.HASMULTIACCESS))
                                                  ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(200): col: 11 Error: Call to a possibly undefined method preventDefault through a reference with
static type qnx.events:ExtendedLocationChangeEvent.
                                event.preventDefault();
                                      ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(202): col: 27 Error: Access of possibly undefined property location through a reference with stat
ic type qnx.events:ExtendedLocationChangeEvent.
                                Utilities.alert(event.location + " is not allowed", webView);
                                                      ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(205): col: 70 Error: Implicit coercion of a value of type qnx.events:ExtendedLocationChangeEvent
to an unrelated type Object.
                                dispatchEvent(new WebkitEvent(WebkitEvent.TAB_LOCATION_CHANGING, event));
                                                                                                 ^
C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\webworks\webkit\WebkitControl.as(22): col: 21 Error: Definition flash.events:LocationChangeEvent could not be found.
        import flash.events.LocationChangeEvent;
                           ^
Loading configuration file C:\Program Files\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp\blackberry-tablet-sdk\frameworks\air-config.xml
[INFO]                  Packaging the bar file
java.io.FileNotFoundException: C:\Users\Kate\AppData\Local\Temp\widgetGen.6029268191295395071353.tmp\sketchPadStandard.swf (The system cannot find the file specified)
        at java.io.FileInputStream.open(Native Method)
        at java.io.FileInputStream.<init>(Unknown Source)
        at net.rim.tumbler.file.FileManager.copyFile(FileManager.java:473)
        at net.rim.tumbler.airpackager.AirPackager.run(AirPackager.java:126)
        at net.rim.tumbler.WidgetPackager.go(WidgetPackager.java:154)
        at net.rim.tumbler.WidgetPackager.main(WidgetPackager.java:80)
[ERROR]                 Air Packager exception occurred
BlackBerry Development Advisor
Posts: 13
Registered: ‎01-14-2010
My Device: Bold 9700
My Carrier: Rogers

Re: Error Compiling the Sample sketchpad Application

Good Morning...

 

It appears that the template is being compiled against an out-of-date Tablet SDK.  Would it be possible for you to post the contents of your bbwp.properties file? (located under bbwp/bin of WebWorks)

 

Also could you let us know where you installed the Webworks SDK.

 

Thanks


Dave

===========================================================================
"Simplicity is the ultimate sophistication" - Leonardo Da Vinci

David Burgess
Team Lead, IDE Extensions Team
Research In Motion

Contributor
Posts: 12
Registered: ‎01-15-2011
My Device: Not Specified

Re: Error Compiling the Sample sketchpad Application

Hello,

 

I'm also facing the same problem. Here is what my bbwp.properties file looks like:

 

 

<?xml version="1.0" encoding="UTF-8"?>
<wcp>
<additional>-quiet</additional>
<java>C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\jre</java>
<wcp_template>AirAppTemplates</wcp_template>
<air_template>AirAppTemplates</air_template>
<tablet_sdk>C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp\blackberry-tablet-sdk</tablet_sdk>
<extension_repository>ext</extension_repository>
</wcp>

 

 

 

Appreciate your help. I'm stuck.
== Keyur

 

 

 

 

New Developer
Posts: 70
Registered: ‎01-13-2011
My Device: Torch 9800 and Playbook
My Carrier: Rogers

Re: Error Compiling the Sample sketchpad Application

 

My bwp.properties
<?xml version="1.0" encoding="UTF-8"?>
<wcp>
<additional>-quiet</additional>
<java>C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\jre</java>
<wcp_template>AirAppTemplates</wcp_template>
<air_template>AirAppTemplates</air_template>
<tablet_sdk>C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp\blackberry-tablet-sdk</tablet_sdk>
<extension_repository>ext</extension_repository>
</wcp>

 

<?xml version="1.0" encoding="UTF-8"?><wcp><additional>-quiet</additional><java>C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\jre</java><wcp_template>AirAppTemplates</wcp_template><air_template>AirAppTemplates</air_template><tablet_sdk>C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook\bbwp\blackberry-tablet-sdk</tablet_sdk><extension_repository>ext</extension_repository></wcp>

 

The sdk was installed to C:\Program Files (x86)\Research In Motion\BlackBerry WebWorks Packager for PlayBook

Highlighted
New Contributor
Posts: 3
Registered: ‎03-21-2011
My Device: Curve 2900
My Carrier: Rogers

Re: Error Compiling the Sample sketchpad Application

The suggested solution in this thread didn't help me by itself, but I found the correct solutions in another thread.

http://supportforums.blackberry.com/t5/Web-Development/PlayBook-Error-Web-Packager-Exception-Occured...

 

I'm posting this here because this was always the first thread to show up for me in the search results.

 

Basically:

1. Learn on your own how to set Environment Variables in windows. I'm not putting it here.

2. Set your JAVA_HOME environment variable to point to the "jre" directory in your sdk path. You may need to add this as a new variable if it doesn't already exist.

For example, mine is JAVA_HOME="C:\RIM\BBPlayBookSDK\jre"

3. Add the "jre\bin" directory to the end of your PATH environment variable.

For example, mine is Path="%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\RIM\BBPlayBookSDK\jre\bin"

 

Good luck!