I dynamically built a form using a RadDocking, then a Vertical RadSplitContainer and inside the RadSpltContainer two Horizontal RadSplitContainers. The lower RadSplitContainer has three RadPaneGroups where the right outer contains three RadPanes.
The right outer container is filled like this:
radPaneGroupSystem.AddItem(ucStatusAlarms, Telerik.Windows.Controls.Docking.DockPosition.Top);
radPaneGroupSystem.AddItem(ucRSSFeed, Telerik.Windows.Controls.Docking.DockPosition.Left);
radPaneGroupSystem.AddItem(ucMessageViewer, Telerik.Windows.Controls.Docking.DockPosition.Right);
If I do that I get a "Object reference not set to an instance of an object." error, source "Telerik.Windows.Controls.Docking",
StackTrace
at Telerik.Windows.Controls.RadPaneGroup.GetPaneGroup()
at Telerik.Windows.Controls.RadPaneGroup.AddItem(RadPane pane, DockPosition dockPosition)
If I change the code and use panegroupParent.Items.Add(ucStatusAlarms), etc I get the three RadPanes as three Tabs functioning normally.
I checked the parameters going into the AddItem call, they are normally set to an instance.
Does anyone know why the Docking gives an Object reference not set to an instance of an object error and what I can do about it?