I'm strimming down a designer I've placed on a form. I want to - by default hide the Dictionary, Report Tree and Properties tabs in the stiDesignerControl. What I want to do is by default either hide the tabs totally - just as if the user had clicked on the X button, or unpin them - just as if the user had clicked on the pin button. Any ideas how I may do this.
Thanks,
Tim.
Hide Dictionary, Report Tree and Properties Tabs in stiDesignerControl
Hide Dictionary, Report Tree and Properties Tabs in stiDesignerControl
In the build from August, 22 we've added a StiDesigner.LoadedDesigner static event. This event is used in the code of this topic.
Please define the following command in any place of your program but be sure that it will be called only once:
Also please define the event handler:
Thank you.
Please define the following command in any place of your program but be sure that it will be called only once:
Code: Select all
StiDesigner.LoadedDesigner += new EventHandler(this.StiDesigner_LoadedDesigner);
Code: Select all
private void StiDesigner_LoadedDesigner(object sender, EventArgs e)
{
StiDockingPanel dockingPanel;
StiDesigner designer = sender as StiDesigner;
StiPanelService serviceTree = StiReportTreePanelService.GetService(designer);
if (!serviceTree.DockingControl.IsVisible)
{
designer.DockingManager.ClosedControls.Remove(serviceTree.DockingControl);
dockingPanel = new StiDockingPanel(designer.DockingManager);
dockingPanel.Controls.Add(serviceTree.DockingControl);
dockingPanel.DockPanelToForm(designer, serviceTree.DockStyle);
}
StiPanelService serviceDictionary = StiDictionaryPanelService.GetService(designer);
if (!serviceDictionary.DockingControl.IsVisible)
{
designer.DockingManager.ClosedControls.Remove(serviceDictionary.DockingControl);
dockingPanel = new StiDockingPanel(designer.DockingManager);
dockingPanel.Controls.Add(serviceDictionary.DockingControl);
dockingPanel.DockPanelToForm(designer, serviceDictionary.DockStyle);
}
StiPanelService serviceProperties = StiPropertiesPanelService.GetService(designer);
if (!serviceProperties.DockingControl.IsVisible)
{
designer.DockingManager.ClosedControls.Remove(serviceProperties.DockingControl);
dockingPanel = new StiDockingPanel(designer.DockingManager);
dockingPanel.Controls.Add(serviceProperties.DockingControl);
dockingPanel.DockPanelToForm(designer, serviceProperties.DockStyle);
}
}
Hide Dictionary, Report Tree and Properties Tabs in stiDesignerControl
Excellent. Thanks.
Hide Dictionary, Report Tree and Properties Tabs in stiDesignerControl
Let us know if you need any help.
Thank you.
Thank you.