There are many ContainerContol in MainWindow. As you can imagine, those ContainerControls are handled with a PagePanel.
According to a host(server) information, whenever user loads necessary data, MainWinow displays relevant information on those ContainerControls.
It works well.
However, when user chooses a different host(server), the displayed information of the previous host is not needed anymore, and user should not be confused with a new host information.
What is a best practice to clear up the previous windows data in ContainerControl?
Can you let me know how to handle it? Clearing listbox, clear textarea and so on manually?
are you asking how to remove the data FROM the controls?
or how to HIDE the controls?
Close to the first one. But, I’m looking for the way to simulate closing window. When we close a window entirely, we can think that the previous data is cleared and the new Window is to ready to display a new information.
That is what I want to implement in ContainerControl.
Assuming that there are A,B,C host category, at first user chooses A host and visits several ContainerControls screen to check the relevant information, then user changes host.
At this time, I need to clear up all of data for host A in ContainerControl.
I think if I would run “listbox.deleteallrows” & putting null string into text related controls, I could clear the data.
But, before doing that, I want to check if there is any simple way.
Because you’ve created the ContainerControl instances in the IDE calling .close will do you no good, so you’d have to write a clear all method on the “master” Then just
If you were to create the ContainerControl instances in code you could close a used one, and open a new one - but you may find yourself having to rework a lot of stuff you already made to implement that.
Making a picture is really important thing at the beginning of stage.
I will implement “MyResetMethod” for clearing up.
Thanks for your advice.