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
New Contributor
Posts: 8
Registered: ‎07-19-2010
My Device: Not Specified

Same Multiple Screen

hello i have couple of queries,

 my application has around 20-25 screens .. whenever  a button is clicked i used to push a new respective screen for that button ..

let say i have 3 buttons that pushes their respective screens when clicked. if i click these buttons one by one and then call for the screen that was already pushed ..what should i do ? shall i push screen again to display it again while it was already in the middle or bottom of stack  or what is the standard way? currently i am pushing the new screen

 

what is the limit of screen in an application stack?...does too many screens in the application stack harms application or can it result in the application crash?

 

please reply..looking for good solution

 

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

Re: Same Multiple Screen

just push a new instance.

if you are concerned about the number of screens you can pop the current and push a new one.

 

with so many screens i would suggest that you consider a tabbed view

----------------------------------------------------------
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: 516
Registered: ‎07-23-2010
My Device: 9900

Re: Same Multiple Screen

If the same buttons are available on the all screens then when you push a new screen pop the old one.

Developer
Posts: 282
Registered: ‎02-25-2010
My Device: curve,bold,storm
My Carrier: Verizon,AT&T

Re: Same Multiple Screen

y dont u pop older screen say screen1 before pushing a new screen say screen2.

 

So that when later on screen! is required u can again push it !!!!!

 

 

Developer
Posts: 468
Registered: ‎08-07-2009
My Device: Curve, Bold, Storm
My Carrier: Blackberry Developer

Re: Same Multiple Screen

hi,

 

 

If the screen you pushed is of no use later then pop the old screen before you push the new screen.

 

 

Thanks

Ekansh

----------------------------------------------------------
feel free to press the kudos button on the left side to thank the user that helped you.
please mark posts as solved if you found a solution.
New Contributor
Posts: 8
Registered: ‎07-19-2010
My Device: Not Specified

Re: Same Multiple Screen

how many screens can be contained in a stack? does pushing repeated screen again and again will make my app heavy or result in crash or anyway effect performance? lets say if my end user uses app very roughly that can lead to 10,000 screens what is the probability that my app would crash?

 

Thanks for the previous replies :smileyhappy:

New Contributor
Posts: 8
Registered: ‎07-19-2010
My Device: Not Specified

Re: Same Multiple Screen

how can i detect that same screen is weather on the stack or not and delete it then?

New Contributor
Posts: 8
Registered: ‎07-19-2010
My Device: Not Specified

Re: Same Multiple Screen

Also if i popped ..back button  would not lead to previous screen rather it would either exit or crash app if no screen is found

Developer
Posts: 468
Registered: ‎08-07-2009
My Device: Curve, Bold, Storm
My Carrier: Blackberry Developer

Re: Same Multiple Screen

Hi,

 

No idea abt stack limit. Pushimg multiple screen will eat your memory and can make your app slow. Yes the app can crash.

 

 

This will help you to find how many screens are in the stack.

 

Ui.getUiEngine().getScreenCount();

 

 

----------------------------------------------------------
feel free to press the kudos button on the left side to thank the user that helped you.
please mark posts as solved if you found a solution.
Developer
Posts: 468
Registered: ‎08-07-2009
My Device: Curve, Bold, Storm
My Carrier: Blackberry Developer

Re: Same Multiple Screen

Can you make a diagramtic representation of your pushing the screen. What actually you are trying.

 

 

----------------------------------------------------------
feel free to press the kudos button on the left side to thank the user that helped you.
please mark posts as solved if you found a solution.