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

Adobe AIR Development

Reply
New Developer
Posts: 9
Registered: ‎04-22-2011
My Device: None
My Carrier: Fido
Accepted Solution

App opens and closes right away!

Hello, 

 

I have succesfully managed to install my application on my playbook simulator(1.0.1).But when I try to launch the app, I get a blackberry logo splash screen for about a second and then it closes and nothing happens, no matter how many times I try to open it always does the same thing. 

 

Thanks

Developer
Posts: 322
Registered: ‎05-07-2009
My Device: BlackBerry Z10, PlayBook, 9900
My Carrier: Telus

Re: App opens and closes right away!

If you swipe up from the bottom bezel does you app still appear to be running?

 

I've encountered this when I have declared a property with a given type, but not actually initialized it... then tried to call a method on it.  It won't fail to compile, but will behave exactly as you described.

 

e.g.

 

public var stuff:Array;

...

...

stuff.push("something");

 

In this scenario stuff is defined as an Array, but never initialized with stuff = new Array();


PlayBook Apps: DataMine, Dots + Boxes, 5 Marbles
BlackBerry SmartPhone Apps: 5 Marbles Soon: **** (D.Z.A), ****Quest, **** Challenge, VaultCracker, DevBrowser, Radial****
Developer
Posts: 1,091
Registered: ‎12-29-2010
My Device: PlayBook, Z10 LE, Dev Alpha C

Re: App opens and closes right away!

Are you using Flash Builder?  Are you getting any console messages?  Are you running a debug configuration or a release configuration?  If running a debug configuration does the debug host IP match in your configuration match your actual host ID?

 

 

You'll get lots of help here but you need to provide details.

New Developer
Posts: 9
Registered: ‎04-22-2011
My Device: None
My Carrier: Fido

Re: App opens and closes right away!

If I swipe up the application is not running.

I have declared all my variables and their constructors properly. So I don't think that is the issue. 

 

I am using flash CS5 to publish my SWF, in the publish settings pannel I have chosen flash player 10 as my target format. I am using the following line in command prompt to install on the target device: 

 

blackberry-deploy -installApp -launchApp -device 192.168.217.129  -package myapp.bar -password playbook

 

I have also used the blackberry-airpackager -package method and the same problem arises. 

 

Would it be better to run a debug configuration? If so how would I do so from the command line?

 

Thanks for helping

Developer
Posts: 1,091
Registered: ‎12-29-2010
My Device: PlayBook, Z10 LE, Dev Alpha C

Re: App opens and closes right away!

Is this the first time you are attempting to run on the sim using this work flow?  Did it ever work before?

 

Have you followed the Flash Pro publishing work flow in the week 2 webcast?

Developer
Posts: 439
Registered: ‎10-25-2010
My Device: Not Specified

Re: App opens and closes right away!

Sounds like youre using AIR 2.6... playbook only supports 2.5
New Developer
Posts: 9
Registered: ‎04-22-2011
My Device: None
My Carrier: Fido

Re: App opens and closes right away!

Hmm I was under the impression that 1.0.1 supported 2.6, anywho 2.6 is installed, how would I install 2.5 back on my machine? 

Developer
Posts: 165
Registered: ‎10-26-2010
My Device: BlackBerry® PlayBook™
My Carrier: .

Re: App opens and closes right away!

AIR 2.6 can compile for AIR 2.5. Just make sure your descriptor has the AIR 2.5 namespace.

As for the disappearing app: http://supportforums.blackberry.com/t5/Tablet-OS-SDK-for-Adobe-AIR/Application-won-t-launch-on-simul...
New Developer
Posts: 9
Registered: ‎04-22-2011
My Device: None
My Carrier: Fido

Re: App opens and closes right away!

Hmm that only half worked. The application doesn't close anymore but it stays stuck on the loading screen. 

 

I tried remaking the same hello world application and for some strange reason there is no problem it loads just fine....guess something somewhere was corrupt on the other files. 

 

Thanks for the help everyone! 

Developer
Posts: 133
Registered: ‎12-02-2010
My Device: Z10 & Dev Alpha C
My Carrier: T

Re: App opens and closes right away!

Try using "-forceAirVersion 2.5" for blackberry packaging options and for Flex Compiling use "-swf-version=10"

 

See: http://deleteaso.com/developing-for-playbook-with-the-air-2-6-sdk/comment-page-1/

---------------------------------------------------------------------
Developer of Stocks for Blackberry 10