How i can close ChildWindow in silverlight from page?
I have page.xaml and childwindow. How i can close the childwindow from page.xaml. Example by click on button in page.xaml. How i can get this childWindow from co开发者_JAVA技巧de?
Name your ChildWindow example x:Name="myChildWindow" under your page.xaml button click event in your code behind put this
myChildWindow.Close();
I believe there is a Close method on the ChildWindow object. By calling this method, the window will close.
See the MSDN documentation.
精彩评论