# UIEVENTS::EVENTS_UI_PEEK_MESSAGE

- **Hash:** `0x90237103F27F7937`
- **Namespace:** UIEVENTS
- **Runtime name (Lua/JS):** `EventsUiPeekMessage`
- **Side:** client (game native)
- **Name status:** official
- **Documentation:** described
- **Since game build:** 1207
- **URL:** https://natives.borderlinerp.com/natives/UIEVENTS/EVENTS_UI_PEEK_MESSAGE

## Signature

```c
BOOL EVENTS_UI_PEEK_MESSAGE(Hash hash, Any* eventData);
```

## Parameters

- `hash` (`Hash`)
- `eventData` (`Any*`)

## Returns

`BOOL`

## Description

eventData: see EVENTS_UI_GET_MESSAGE

Old name: _EVENT_MANAGER_PEEK_EVENT

## Usage

### Lua

```lua
local retval, eventData = EventsUiPeekMessage(hash, eventData)

-- always available, by hash
local retval, eventData = Citizen.InvokeNative(0x90237103F27F7937, hash, Citizen.PointerValueIntInitialized(eventData), Citizen.ReturnResultAnyway())
```

### JavaScript

```js
const [retval, eventData] = EventsUiPeekMessage(hash, eventData);

// by hash
const [retval, eventData] = Citizen.invokeNative('0x90237103F27F7937', hash, Citizen.pointerValueIntInitialized(eventData), Citizen.returnResultAnyway());
```

### C#

```csharp
var eventData = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x90237103F27F7937, hash, eventData);
// eventData.GetResult<int>()
```

- Hash parameters: the named function also accepts a string and hashes it for you; `Citizen.InvokeNative` needs the number — pass `joaat("name")` or a backtick literal like `` `name` ``.
- The last argument is an in/out pointer: pass its initial value, and the updated value is returned after the result.
- `Any*` arguments are often structs. Build them with a DataView buffer and pass it with `:Buffer()` — see the examples and notes below.

*Sources: alloc8or RDR3 NativeDB.*
