BlackBerry Forums Support Community
              

Closed Thread
 
Thread Tools
Old 03-14-2010, 10:08 AM   #1
satyarajasekhar
Knows Where the Search Button Is
 
Join Date: Mar 2009
Model: 8100
PIN: N/A
Carrier: AIRTEL
Posts: 25
Default Sending data from Popped Screen to the Screen behind popped screen

Please Login to Remove!

Hi,
I am pushing a popupscreen from one screen which contains choice fields. In the popup screen i am having some choice fields and after selecting some choice, i had to send that value to the previous screen i.e, screen behind the popped screen.
How to send the data from front screen to the back screen.

Please help me in this aspect.

Thanks,
RAJ
Offline  
Old 03-14-2010, 11:22 AM   #2
jacob.tabak
Knows Where the Search Button Is
 
Join Date: Mar 2010
Model: N/A
PIN: N/A
Carrier: Fledge
Posts: 43
Default

In the constructor to your popup screen, pass a reference to the screen behind the previous screen. Then you can update the fields of the other screen directly.

The preferred way of doing this is through public getter/setter methods in the previous screen like:
public void receiveMessageFromPopup(String message)

If you need more tips on the specific implementation of this, feel free to ask.
Offline  
Old 03-14-2010, 07:21 PM   #3
satyarajasekhar
Knows Where the Search Button Is
 
Join Date: Mar 2009
Model: 8100
PIN: N/A
Carrier: AIRTEL
Posts: 25
Default Sending data from Popped Screen to the Screen behind popped screen

Hi,
Thanks for your reply and it works like a perfect charm. But, thing is, is it creates cluttering of class handlers in the mobile i.e, is the application becomes slow when i do such kind of passing the reference to other class.

Please help me in this regard.
Offline  
Old 03-14-2010, 10:33 PM   #4
jacob.tabak
Knows Where the Search Button Is
 
Join Date: Mar 2010
Model: N/A
PIN: N/A
Carrier: Fledge
Posts: 43
Default

No, this is standard practice in Java and an object oriented principle called composition. It's similar to a pointer in C++ and doesn't consume any more memory than a string variable would.

The only effect this will have on performance is that an object that is referenced by other active objects will not be garbage collected. However, in your case, it wouldn't make any sense for the original object to be garbage collected because it's in the background and will be displayed later.

So basically the only time this would have an adverse effect on performance is when you are needlessly passing around references to objects that should be garbage collected.
Offline  
Closed Thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


NEW Polycom VVX 501 VoIP IP Phone & Stand Warranty VVX411 2200-48500-019 Lync picture

NEW Polycom VVX 501 VoIP IP Phone & Stand Warranty VVX411 2200-48500-019 Lync

$49.98



Polycom VVX 501 VoIP IP Phone & Stand Blem Warranty VVX501 2201-48500-001 picture

Polycom VVX 501 VoIP IP Phone & Stand Blem Warranty VVX501 2201-48500-001

$19.98



Polycom VVX 400 VoIP IP Phone & Stand Warranty Reset 2201-46104-001 SIP or Skype picture

Polycom VVX 400 VoIP IP Phone & Stand Warranty Reset 2201-46104-001 SIP or Skype

$19.98



Polycom Vvx 601 VoIP 16 Line Business Phone 4.3

Polycom Vvx 601 VoIP 16 Line Business Phone 4.3" HD Touchscreen PoE With Stand

$28.95



Polycom SoundStation IP 6000 VoIP Conference Phone - No cords, No Accessories picture

Polycom SoundStation IP 6000 VoIP Conference Phone - No cords, No Accessories

$18.00



Allworx 9212 VoIP IP Phone with Stand Warranty Paetec 9212P Business Office picture

Allworx 9212 VoIP IP Phone with Stand Warranty Paetec 9212P Business Office

$17.98







Copyright © 2004-2016 BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of BlackBerry Inc.