Hi Qingde,
Thanks for contacting Syncfusion support.
We have analyzed your query and prepared sample to meet your requirement. In this sample we have changed the visibility of the TabPrimitivesHost to true, if the total width of the TabPages are greater than tabcontrol’s width. Otherwise visibility of the TabPrimitivesHost will be false. Please download the sample for the same from below location,
Please find the code example to update the visibility of the TabPrimitiviesHost from below table,
private void UpdatePrimitiveHostVisibility()
{
int TabRectWidth = 0;
if (this.tabControlAdv1 != null && this.tabControlAdv1.TabPages != null)
{
for (int i = 0; i < this.tabControlAdv1.TabPages.Count; i++)
{
TabRectWidth += this.tabControlAdv1.GetTabRect(i).Width;
}
if (this.tabControlAdv1.Width < TabRectWidth)
{
this.tabControlAdv1.TabPrimitivesHost.Visible = true;
}
else
{
this.tabControlAdv1.TabPrimitivesHost.Visible = false;
}
}
} |
If we misunderstood your query please provide more details about your requirement with sample. This would help us to provide the solution at earliest.
Regards,
Durga S.