# ObjectGethWnd Event

> Occurs when a document with objects inserted through their hWnd property is loaded; the application recreates each control and passes its hWnd back.

- **Product:** TX Text Control ActiveX
- **Section:** Documentation
- **Kind:** Event
- **Path:** TX Text Control ActiveX > API Reference > TXTextControl > ObjectGethWnd Event
- **318 words**
- **Web URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectgethwnd-event/
- **LLMs URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectgethwnd-event/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectgethwnd-event/llms-full.txt

---

Occurs when a document which contains objects, is loaded. This event is sent only for objects that have been inserted via its hWnd property. The application must create the object and copy the object's hWnd property to the hWnd parameter.

### Syntax

```vbscript
ObjectGethWnd(ObjectId, KindOfObject, hWnd)
```

### Parameters

| Parameter | Description |
|---|---|
| ObjectId | Is the identifier of the object that is to be created. |
| KindOfObject | Is the value that has been specified as KindOfObject parameter for the [ObjectInsertAsChar](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectinsertaschar-method/llms-full.txt), [ObjectInsert](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectinsert-method/llms-full.txt) or [ObjectInsertFixed](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectinsertfixed-method/llms-full.txt) method. |
| hWnd | The hWnd property of the new created object must be copied to this variable. |

### Data Types

| Name | Data type |
|---|---|
| ObjectId | Integer |
| KindOfObject | Integer |
| hWnd | Handle |

### See Also

- [ObjectGetData Event](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectgetdata-event/llms-full.txt)
- [ObjectSetData Event](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectsetdata-event/llms-full.txt)
- [Programming Category: Images, Text Frames, Signature Fields and OLE Objects](https://docs.textcontrol.com/tx-text-control-activex/reference/categories/images-objects/llms-full.txt)

---

## Nearby

- **Previous:** [ObjectGetFromUserId Method](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectgetfromuserid-method/llms-full.txt)
- **Next:** [ObjectGetSelected Method](https://docs.textcontrol.com/tx-text-control-activex/reference/txtextcontrol/objectgetselected-method/llms-full.txt)
