Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Closing Window (Read 1363 times)
monkeydll
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 41
Joined: Jun 27th, 2016
Closing Window
Sep 6th, 2016 at 7:56am
Print Post  
Hello.
I want to close all of my open windows when I click on a button.
My windows are being opened in a windowHost and the windowHost is inside a userControl.
I have searched for a close method but it doesnt exist.
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3147
Joined: Oct 19th, 2005
Re: Closing Window
Reply #1 - Sep 6th, 2016 at 8:13am
Print Post  
Hi,

You can remove them from the WindowHost.Windows collection. It would be nice if WindowHost.Windows.Clear worked, but our developers haven't implemented it, so try this -

Code
Select All
while (windowHost.Windows.Count > 0)
	windowHost.Windows.RemoveAt(0); 



Regards,
Slavcho
Mindfusion
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint