Get containt form patent window in child window - silverlight

I want to create a child window in silverlight 4 but when the child window pop-up the parent window should not be disable.
I should able to access control or properties from parent window how do i do this.
Whether its possible?

Set OverlayBrush property of ChildWindow to transparent color

I think that you can find solution in FloatableWindow here.

Related

wpf 4.0 partial button outside of main window

I'm trying to figure out a way to have a selected button/item extend past the main window and 'connect' to the spawned window. I'm thinking that a transparent window behind the 'toolbar' window and the spawned item. Am I on the right track?
Here is what I'm trying to do:
Thanks for the input.
You look like you on the right track. A control cannot extended beyond the bounds of a window so you would have to make the window transparent and color only part of the window to make it look as if the selected item is extended beyond the window bounds.

Child wpf window above parent window

I have WPF application with main window. I want to create child WPF window which always must be above ONLY parent window. If I set TopMost property for new window then window is above ALL nonTopMost windows on desktop. It's not what I want.
Set the Owner property of the child window so that it refers to the parent window.
child.Owner = parent;
Depending on the nature of the window, I often use a "Fake" window that is really just a layer in the parent along with a partailly transparent grey layer between that makes the parent look ghosted while the child is active. You can then keep the child window set to collapsed until it is needed.

How to stop WPF TopMost flag on parent window from being inherited by the child

I have a WPF window that has TopMost=true . When I call another Window from this window and specify the topmost window as the parent the owned window also displays as TopMost.
I would like to find a way to stop that from happening so that my parent can still own the child yet the child does not have TopMost=True.
I know I can just not bother to set the owner on the child then I won't get the TopMost flag, but I need all my windows to close with the parent window and writing the logic to handle that seems like a waste when it is included.
I've tried to explicitly set the TopMost=False after the child was loaded but no luck, it doesn't seem to matter if the owner window is TopMost then the child will be no matter what I do to it's TopMost property.
Any ideas?
Set The TopMost of the (parent) window, at runtime. (and not by default)

WPF Close UserControl in Frame and access Parent Controls

I have a WPF app with a Window (RootWindow) with a Toolbar and a Frame (ContentFrame). Initially the Toolbar is hidden.
I load a Login UserControl into the Frame and when the user correctly logs in I'd like to close the UserControl and then make the Parent Window toolbar visible.
Seems such a simple thing to do.
However, you cannot close a UserControl from within the UserControl. So how do I break out of the UserControl so I can remove it from the RootWindow (ContentFrame.Source=Nothing) and also make the toolbar Visible.
I can get a handle for the Parent Window with the following code but I cannot access the controls within it
Dim parentWindow As Window = Window.GetWindow(Me) 'Get a handle for parent window
Ideally, I'd like to be able to access Parent Window Controls from within a Child UserControl or at least be able to Trigger an event in the Parent Window from the Child UserControl.
To find the parent in the hirearchy you can use this code:
http://www.hardcodet.net/2009/03/detecting-double-click-events-on-the-wpf-datagrid
Although the problem solved in above article is for DataGrid, the code to find parent is generic enough and should work in your case.

WPF usercontrol

I facing very huge problem now,
that is I have usercontrol (created by me) which I have added on to a window...
on click of button I wann show another usercontrol on window, total how can I access the window object in my control (usercontrol)
Thanks all
You can use Window.GetWindow. However, you might want to consider a redesign where the Window is responsible for its content, not something hosted inside the Window.
You could do that by accessing the Parent property.
But why not raising an event from the UserControl which is handled in the window, and there you add the other control?
Or you could create an event and a delegate in the usercontrol and handle it in the Window.

Resources