# CachedMessageBlock.TryFindNextMessage(int, StreamId, ICacheDataAdapter, int)

[Type overview](/orleans/docs/api/csharp/microsoft.orleans.streaming/orleans.providers.streams.common.cachedmessageblock/) | [Methods](/orleans/docs/api/csharp/microsoft.orleans.streaming/orleans.providers.streams.common.cachedmessageblock/methods/)

[Source](https://github.com/dotnet/orleans/blob/e4e752cedecc2976811db49802c7a999b1f1c704/src/Orleans.Streaming/Common/PooledCache/CachedMessageBlock.cs#L205-L220)

```csharp
public bool TryFindNextMessage(int start, StreamId streamId, ICacheDataAdapter dataAdapter, out int index)
```

Tries to get the next message from the provided stream, starting at the start index.

### Parameters

- `start` (`int`): The start index.
- `streamId` (`StreamId`): The stream identifier.
- `dataAdapter` (`ICacheDataAdapter`): The data adapter.
- `index` (`int`): The index.

### Returns

`true` if the message was found, `false` otherwise.
