5 Answers, 1 is accepted
Thank you for writing.
Consider the following code snippet which achieves your scenario:
ToolWindow toolWindow =
new
ToolWindow(
"Tool Window"
);
this
.radDock1.DockWindow(toolWindow, toolWindow, DockPosition.Left);
toolWindow.AutoHide();
I hope this will help you. If you have further questions, I would be glad to help.
Kind regards,
Ivan Petrov
the Telerik team
Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!
Thank you for your reply.
This part is working fine, but what about the other way around?
Now showing this Hidden Toolwindow ?
As i told before, i tried Toolwindow.Show() but that doesn't work.
I don't want t change the DockingState, I only want to show the ToolWindow
Regards Viktor
Thank you for your replay.
From what I understand you want to show a given tool window that is already hidden as if you have hovered it with the mouse. For this scenario you will have to use reflection as the method which is responsible for the showing of a tool window is not public. Please consider the following code snippet:
MethodInfo method =
this
.radDock1.GetType().GetMethod(
"ShowAutoHidePopup"
, System.Reflection.BindingFlags.Instance | System.Reflection.BindingFlags.NonPublic);
if
(method !=
null
)
{
method.Invoke(
this
.radDock1,
new
object
[] {
this
.toolWindow.AutoHideTab, AutoHideDisplayReason.TabItemClicked });
}
I hope this is what you are looking for. Should you have further questions, feel free to contact us. All the best,
Ivan Petrov
the Telerik team
Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!
EDIT: Nevermind ;)
Thank you for writing.
In case someone else looks for this information, there is now a public ShowAutoHidePopup method which can be used to accomplish this task.
If you have other questions, feel free to write back.
All the best,
Ivan Petrov
the Telerik team