Destroy 'Dialog' Panels

enonod

Well-Known Member
Licensed User
Longtime User
I have five sets of code to create 5 populated panels (listview etc.) as sort of dialogs.
They then reside in memory and I use visible to show them or hide them.
Naturally the creation code is still present also.
My thinking is that memory can be saved by destroying these panels after each use, and using the already available creation code to re-create them when needed. Speed is not an issue.

Is there a way to destroy the panels without individually removing each item; which would defeat the object.
 

enonod

Well-Known Member
Licensed User
Longtime User
You have asked a question I cannot answer. I have never read up on that nor given it any consideration. In my mind, creating a panel and making it visible or not was the way.
The panels are not different programs, they are similar to dialogs; either for viewing or selecting/filling in and not used often.
Perhaps you would be good enough to enlighten me on this unknown area.
 
Upvote 0

enonod

Well-Known Member
Licensed User
Longtime User
I am grateful for your suggestion and will read up before moving on.
Perhaps I can come back if my memory question is not satisfied.
 
Upvote 0

enonod

Well-Known Member
Licensed User
Longtime User
Thank you for that suggestion which will solve everything. That was very enlightening.
Please correct me if I am wrong that any data, say from EditText etc, must be passed between activities via Process Globals, and that is simply because only the current activity exists... live.
 
Upvote 0

enonod

Well-Known Member
Licensed User
Longtime User
My thanks for that confirmation.
 
Upvote 0

enonod

Well-Known Member
Licensed User
Longtime User
aha! The flaw in the system I believe. I don't want the 'dialog panels filling the screen. I do not see that a new Activity can be otherwise.
 
Upvote 0

enonod

Well-Known Member
Licensed User
Longtime User
At the risk of annoying... back then to the original question but I have learnt some useful stuff.

Is there a way to destroy the panels without individually removing each item; which would defeat the object?
 
Upvote 0

enonod

Well-Known Member
Licensed User
Longtime User
That is great and thank you klaus
 
Upvote 0
Top