how to remove a Form from memory after showback()

66 views
Skip to first unread message

romanca...@gmail.com

unread,
Mar 27, 2017, 11:26:52 PM3/27/17
to CodenameOne Discussions
Hi! what is the right way to remove a Form from memory after a showBack?

thanks!


If you are experiencing an issue please mention the full platform your issue applies to:
IDE: NetBeans/Eclipse/IDEA
Desktop OS
Simulator
Device

Steve Hannah

unread,
Mar 28, 2017, 12:19:11 PM3/28/17
to codenameone...@googlegroups.com
As long as you're not keeping an active reference to the Form object, it will be garbage collected.

Steve

--
You received this message because you are subscribed to the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsub...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit https://groups.google.com/d/msgid/codenameone-discussions/beb9a6a6-30a9-410c-809b-c3abb40e294f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Steve Hannah
Software Developer
Codename One

Dr. Roman Javier Canoniero

unread,
Mar 28, 2017, 2:41:07 PM3/28/17
to codenameone...@googlegroups.com
steve:
 
i use :
 
                  myForm form1 = new myForm(Display.getInscance().getCurrent());
                   form1.show();
 
and  when i postback i put:
 
                    prevForm.showBack();
 
in my custom form class i set prevForm with the Display.getInscance().getCurrent() what i sent as parameter.
 
several times, when i postback CN1 sends me to forms who was opened before but are not the previous
You received this message because you are subscribed to a topic in the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codenameone-discussions/4yqve5ABAOI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codenameone-discu...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



Avast logo

This email has been checked for viruses by Avast antivirus software.
www.avast.com


Steve Hannah

unread,
Mar 29, 2017, 1:58:58 PM3/29/17
to codenameone...@googlegroups.com
Probably your "back" event is being hit twice so it calls the "back" action of both the current form, and the previous form somehow.  It's hard for me to comment further without a concrete test case to look at. 

Steve

To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsubscr...@googlegroups.com.


 
--
Steve Hannah
Software Developer
Codename One
--
You received this message because you are subscribed to a topic in the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codenameone-discussions/4yqve5ABAOI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codenameone-discussions+unsub...@googlegroups.com.



Avast logo

This email has been checked for viruses by Avast antivirus software.
www.avast.com


--
You received this message because you are subscribed to the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsub...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.

For more options, visit https://groups.google.com/d/optout.

romanca...@gmail.com

unread,
Mar 29, 2017, 3:46:15 PM3/29/17
to CodenameOne Discussions
steve : its any way to sent you a video with the effect?
Steve

To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsub...@googlegroups.com.
--

Steve Hannah

unread,
Mar 30, 2017, 12:34:04 PM3/30/17
to codenameone...@googlegroups.com
You can post a video on youtube and post the link.  Also make sure to share the code you're using (and make it minimal to the test case).  

Steve

Steve

To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsubscr...@googlegroups.com.


 
--
Steve Hannah
Software Developer
Codename One
--
You received this message because you are subscribed to a topic in the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codenameone-discussions/4yqve5ABAOI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codenameone-discussions+unsubscr...@googlegroups.com.



Avast logo

This email has been checked for viruses by Avast antivirus software.
www.avast.com


--
You received this message because you are subscribed to the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsubscr...@googlegroups.com.



--
Steve Hannah
Software Developer
Codename One

--
You received this message because you are subscribed to the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codenameone-discussions+unsub...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.

For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages