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

Java Development

Reply
Developer
Posts: 35
Registered: ‎11-26-2008
My Device: 8100

problem in pushScreen

i am using 4.7 JDE with storm simulator

 

i have 2 screens

s1 and s2

 

i have pushed s2 from s1

then coming back to s1 by following code

 

---------

UiApplication.getUiApplication().popScreen(UiApplication.getUiApplication().getActiveScreen());

---------

this code is in s2 in keyChar function on Characters.ESCAPE event

 

now i can not go to s2

it shows me following error

 

-----

No stack trace

-----

 

i do not where the problem is ?

 

everytime every objects get created newly when screen is pushed

 

i tracked s2 class file... no clue

Developer
Posts: 17,011
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: problem in pushScreen

what is the code you use to push your s2 screen?
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Developer
Posts: 35
Registered: ‎11-26-2008
My Device: 8100

Re: problem in pushScreen

----

UiApplication.getUiApplication().pushScreen(s2's screen object);

----

 

 

FYI:

in s2 class, there is a code which calls a HTTP request and i just parse that response and fill the screen

but i traced this. it makes a HTTP request again.

Developer
Posts: 17,011
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: problem in pushScreen

ah, i think i misunderstood your initial problem.

after you use popscreen on s2 the screen is gone (unless you hold a reference).
you have to create and push it again (or push the reference if you are holding one) to get it displayed.

blocking stuff like networking should be processed in a different thread.
----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter