I have a pane docked to the bottom of my application. I will like the pane to always be visible and not movable. I am able to accomplish this by setting the properties AllowClose, AllowDockAsTab, AllowDragging, AllowFloating, and AllowPin to false. I also want to prevent other tabs from being docked to that dock area, but I have not been able to do that. Basically, I want the pane to be the only pane in the group. How do I accomplish this? I have not found a property that will allow me to do this. Do I need to handle an event to prevent other tabs from being added to the group?
It seems like you want a panel that doesn't move at all. So then the question is.. why even use a DockPane for that? I think Divya is suggesting that you just use a regular panel or UltraPanel control. That way it will not be docked and there will be no way for the user to move it or add tabs to it. If you need the pane to be collapsible, you could use UltraExpandableGroupBox which allows expanding and collapsing. If you must use a Dock pane, then be aware that there are probably a bunch of other undesirable behaviors you will need to deal with. For example, I suspect that in addition to allowing the user to add a tab into it, they can also place another pane BELOW it, which will also cause it to shift position. I don't think AllowDragging will prevent that - the user can still drag other panels into positions that will force the panel on the bottom to move.
You might be able to handle that via the events of the DockManager. Perhaps there are some cancellable events and you could detect the case when the bottom panel would move based on the current drag/drop operation. But even if that is the case, it will not be easy to detect and the user will not know they can't drop the panel into that position until after they try. So I don't think that's a feasible solution.
Divya, I am not sure what you mean by an expansion panel. By looking at the code, I see that DragManager.PaneLocator.FindPanelElement is what finds the drop target when dragging. I will like to add a setting to DockAreaPane or DockAreaPane.Setting that FindPanelElement will check to determine if the DockAreaPane is a valid target. Is that reasonable? If so, what do I need to modify to make that happen?
Hello Jose,
Thank you for posting. Unfortunately, we do not have any property /event exposed to prevent a tab being docked to the existing dock.But if you want only this pane in the group then why don’t you use a panel or maybe expansion panel .
Let me know if you have any question.
Regards,Divya Jain