# Text Search Panel

Learn about Text Search Panel in PrintDocument from this WinForms documentation helpfile.

## Content



Both the PrintPreview and RibbonPreview libraries provide the **Text Search Panel** control to enable the end-user to search text within the document displayed on the preview pane. To invoke the text search panel, you can press the CTRL + F key combination, or use the Search ![](https://cdn.mescius.io/document-site-files/images/6772f728-508e-4e80-9394-208f07d64beb/images/search-icon.png)command in the top toolbar of the PrintPreview control (or RibbonPreview control).

![Snapshot showing text search panel ](https://cdn.mescius.io/document-site-files/images/6772f728-508e-4e80-9394-208f07d64beb/images/search-textpanel-preview.png)

The available search options are as given below:

**Match Case** : Matches letter casing while performing the text search.

**Match Whole**: Matches the entire search text only.

**Search Up**: Specifies if the text search can be performed from the bottom of the control up.

The search panel can be hid after usage by clicking the **Hide** button. Further, you can click the Search button on the toolbar or use the shortcut key (CTRL + F) once again to hide the search panel.

The PrintPreview and RibbonPreview libraries also provide the users with two UI-style options for the Text Search control, panel (default) and toolbar.

To add a toolbar-style search panel, use the following code snippet:

```csharp
c1PrintPreviewControl1.TextSearchUIStyle = TextSearchUIStyle.ToolBar;
```

The resulting output on invoking the search command is as follows:

![Horizontal text search panel](https://cdn.mescius.io/document-site-files/images/6772f728-508e-4e80-9394-208f07d64beb/images/textsearch-uipanel-toolbarstyle.png)