# BookmarkDialog Class

> The BookmarkDialog class implements a Windows Forms dialog box to insert a DocumentTarget at the current input position. If there is a target at the current input position, the name of the target is shown and can be edited. The dialog box can only be opened, if either DocumentTargetCollection.CanAdd returns true or if DocumentTargetCollection.GetItem() does not return null. Otherwise, an exception occurs. Each item of the dialog box has a name, available through its Name property, which corresponds with a member of the BookmarkDialog.DialogItem enumeration. The BookmarkDialog.FindItem method can be used to get a certain item and manipulate, move or delete it. The BookmarkDialog is a modal dialog box which must be shown with the BookmarkDialog.ShowDialog method.

- **Product:** TX Text Control .NET for Windows Forms
- **Section:** Reference
- **Kind:** Class
- **Introduced:** 23.0
- **Namespace:** `TXTextControl`
- **Package:** `TXTextControl.TextControl.WinForms.SDK` (assembly `TXTextControl.Windows.Forms.dll`, from the private NuGet feed or Text Control Offline Packages)
- **.NET Framework:** reference `TXTextControl.Windows.Forms.dll` from the setup
- **Inherits:** `System.Windows.Forms.Form`
- **Path:** TX Text Control .NET for Windows Forms > Reference > TXTextControl > BookmarkDialog Class
- **1060 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/llms-full.txt

---

### Description

The BookmarkDialog class implements a Windows Forms dialog box to insert a [DocumentTarget](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/documenttarget/llms-full.txt) at the current input position. If there is a target at the current input position, the name of the target is shown and can be edited. The dialog box can only be opened, if either [DocumentTargetCollection.CanAdd](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/textfieldcollectionbase/canadd-property/llms-full.txt) returns true or if [DocumentTargetCollection.GetItem()](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/documenttargetcollection/getitem-method/llms-full.txt) does not return null. Otherwise, an exception occurs. Each item of the dialog box has a name, available through its Name property, which corresponds with a member of the [BookmarkDialog.DialogItem](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/dialogitem-enumeration/llms-full.txt) enumeration. The [BookmarkDialog.FindItem](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/finditem-method/llms-full.txt) method can be used to get a certain item and manipulate, move or delete it. The BookmarkDialog is a modal dialog box which must be shown with the `BookmarkDialog.ShowDialog` method.

### Syntax

```csharp
public class BookmarkDialog : Form
```

```vbnet
Public Class BookmarkDialog
    Inherits Form
```

### Examples

The following example creates an BookmarkDialog object and shows the dialog box:

```csharp
BookmarkDialog dlg = new BookmarkDialog(textControl1);
dlg.ShowDialog();
```

```vbnet
Dim dlg As New BookmarkDialog(textControl1)
dlg.ShowDialog()
```

The following example creates a Bookmark Dialog instance and configures its allow transparency setting for a document workflow.

```csharp
using BookmarkDialog bookmarkDialog = new(new TextControl());
bookmarkDialog.AllowTransparency = true;
```

```vbnet
Dim bookmarkDialog As New BookmarkDialog(New TextControl())
bookmarkDialog.AllowTransparency = True
```

---

## In This Section

- [BookmarkDialog Constructor](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/constructor/llms-full.txt): Creates a BookmarkDialog object for the specified Windows Forms TextControl.
- [BookmarkDialog.DialogItem Enumeration](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/dialogitem-enumeration/llms-full.txt): Each DialogItem represents an item in a BookmarkDialog dialog box. The corresponding string of a DialogItem is the same as the item's Name property. The DialogItem enumeration can be used with the BookmarkDialog.FindItem method to get the item and manipulate it.
- [BookmarkDialog.FindItem Method](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/finditem-method/llms-full.txt): Finds a control that has the provided identifier name.

---

## Nearby

- **Previous:** [BinaryStreamType Enumeration](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/binarystreamtype/enumeration/llms-full.txt)
- **Next:** [BookmarkDialog Constructor](https://docs.textcontrol.com/tx-text-control-dotnet-winforms/reference/txtextcontrol/bookmarkdialog/constructor/llms-full.txt)
