How to hide the ‘X’ close button on an XPTaskPane
Use the XPTaskPane's HeaderRightToolbar property to capture the XPToolbar on the right-top corner of the XPTaskPane. Then access its Items Collection and set the second BarItem's (index value = 1, which is actually the 'X' close button) Visible property to False as shown in the code below:
C#
Syncfusion.Windows.Forms.Tools.XPMenus.BarItem bitem = this.xpTaskPane1.HeaderRightToolbar.Items[1];
bitem.Visible = false;VB
Syncfusion.Windows.Forms.Tools.XPMenus.BarItem bitem =Me.xpTaskPane1.HeaderRightToolbar.Items(1)
bitem.Visible = FalseConclusion
I hope you enjoyed learning about how to hide the ‘X’ close button on an XPTaskPane.
You can refer to our WinForms XPTaskPane control documentation page to know about its other groundbreaking feature representations.
For current customers, you can check out our components from the License and Downloads page. If you are new to Syncfusion, you can try our 30-day free trial to check out our other controls.
If you have any queries or require clarifications, please let us know in the comments section below. You can also contact us through our support forums, Direct-Trac, or feedback portal. We are always happy to assist you!