Silverlight 2 is a great platform but it has some bugs. One of them is the bug where you are not allowed to call TransformToVisual
method from an element that is not in the main visual tree. Now this is a real problem especially for RadWindow because the window is not in the main visual tree. RadWindow is displayed in Popup control and the visual tree of the popup is not connected with the main visual tree (the main visual tree is the tree from Application.Current.RootVisual
). So in order to be able to call TransformToVisual
from RadWindow and its content we need to attach the window popup to the main visual tree. But to be able to do it we need Application.Current.RootVisual
to be created.
The general recommendation is to open RadWindow after the Page Loaded event has been fired.
So in your case if you move window opening in loaded event - everything should be working fine.
I am sorry for the inconvenience but until Microsoft fix this bug we cannot offer better solution.
the Telerik team
Check out Telerik Trainer
, the state of the art learning tool for Telerik products.