# TargetDelete Method

> Deletes the link target or bookmark with the identifier returned by the TargetInsert method from the document and returns True or False.

- **Product:** TX Text Control ActiveX
- **Section:** Documentation
- **Kind:** Method
- **Path:** TX Text Control ActiveX > API Reference > TXTextControl > TargetDelete Method
- **211 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/targetdelete-method/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/targetdelete-method/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/targetdelete-method/llms-full.txt

---

This method can be used to delete a link target or bookmark from the document.

Introduced: 28.0.

### Syntax

```vbscript
TXTextControl.TargetDelete TargetId
```

### Parameters

| Parameter | Description |
|---|---|
| TargetId | Specifies the link target's unique identifier. This must be the value returned from the [TargetInsert](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/targetinsert-method/llms-full.txt) method. |

### Return Value

The return value is True, if the specified target could be deleted. Otherwise, it is False. False is returned, if an error occurred or if the specified target id is invalid.

### Data Types

| Name | Data type |
|---|---|
| TargetId | Long |
| Return value | Boolean |

### See Also

- [Marked Text Fields](https://docs.textcontrol.com/tx-text-control-activex/document-editor/fields/llms-full.txt)
- [Programming Category: Hypertext Links](https://docs.textcontrol.com/tx-text-control-activex/reference/categories/hypertext-links/llms-full.txt)

---

## Nearby

- **Previous:** [TargetData Property](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/targetdata-property/llms-full.txt)
- **Next:** [TargetDeleted Event](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/targetdeleted-event/llms-full.txt)
