# Pinning the DockingTab

Get started with Menus and Toolbars for WinForms. Create versatile menus and docking/floating toolbars. See more in documentation here.

## Content



To pin the [C1DockingTab](/componentone/docs/win/online-menus-toolbar/) programmatically, set the [AutoHiding](/componentone/docs/win/online-menus-toolbar/) property of the [C1DockingTab](/componentone/docs/win/online-menus-toolbar/) to **False**. Use the following code:

DOC-DETAILS-TAG-OPEN

DOC-SUMMARY-TAG-OPEN

To write code in Visual Basic

DOC-SUMMARY-TAG-CLOSE

```vbnet
Me.C1DockingTab1.AutoHiding = False
```

DOC-DETAILS-TAG-CLOSE

DOC-DETAILS-TAG-OPEN

DOC-SUMMARY-TAG-OPEN

To write code in C#

DOC-SUMMARY-TAG-CLOSE

```csharp
this.C1DockingTab1.AutoHiding = False;
```

DOC-DETAILS-TAG-CLOSE


> type=note
> **Note**: To correctly pin and unpin the C1DockingTab, it must be placed in a C1CommandDock control.

## See Also

[Preventing the Tabs from Receiving Focus on Mouse Click](/componentone/docs/win/online-menus-toolbar/menusandtoolbarsforw2/dockingtabtasks/preventingthetabsfro)