Table of Contents

Method SendPaginatedMessageAsync

Namespace
DSharpPlus.Interactivity
Assembly
DSharpPlus.Interactivity.dll

SendPaginatedMessageAsync(DiscordChannel, DiscordUser, IEnumerable<Page>, PaginationButtons, PaginationBehaviour?, ButtonPaginationBehavior?, CancellationToken)

Sends a paginated message with buttons.

public Task SendPaginatedMessageAsync(DiscordChannel channel, DiscordUser user, IEnumerable<Page> pages, PaginationButtons buttons, PaginationBehaviour? behaviour = null, ButtonPaginationBehavior? deletion = null, CancellationToken token = default)

Parameters

channel DiscordChannel

The channel to send it on.

user DiscordUser

User to give control.

pages IEnumerable<Page>

The pages.

buttons PaginationButtons

Pagination buttons (pass null to use buttons defined in InteractivityConfiguration).

behaviour PaginationBehaviour?

Pagination behaviour.

deletion ButtonPaginationBehavior?

Deletion behaviour

token CancellationToken

A custom cancellation token that can be cancelled at any point.

Returns

Task

SendPaginatedMessageAsync(DiscordChannel, DiscordUser, IEnumerable<Page>, PaginationButtons, TimeSpan?, PaginationBehaviour?, ButtonPaginationBehavior?)

Sends a paginated message with buttons.

public Task SendPaginatedMessageAsync(DiscordChannel channel, DiscordUser user, IEnumerable<Page> pages, PaginationButtons buttons, TimeSpan? timeoutoverride, PaginationBehaviour? behaviour = null, ButtonPaginationBehavior? deletion = null)

Parameters

channel DiscordChannel

The channel to send it on.

user DiscordUser

User to give control.

pages IEnumerable<Page>

The pages.

buttons PaginationButtons

Pagination buttons (pass null to use buttons defined in InteractivityConfiguration).

timeoutoverride TimeSpan?

Override timeout period.

behaviour PaginationBehaviour?

Pagination behaviour.

deletion ButtonPaginationBehavior?

Deletion behaviour

Returns

Task

SendPaginatedMessageAsync(DiscordChannel, DiscordUser, IEnumerable<Page>, PaginationBehaviour?, ButtonPaginationBehavior?, CancellationToken)

Sends a paginated message with buttons.

public Task SendPaginatedMessageAsync(DiscordChannel channel, DiscordUser user, IEnumerable<Page> pages, PaginationBehaviour? behaviour = null, ButtonPaginationBehavior? deletion = null, CancellationToken token = default)

Parameters

channel DiscordChannel

The channel to send it on.

user DiscordUser

User to give control.

pages IEnumerable<Page>

The pages.

behaviour PaginationBehaviour?

Pagination behaviour.

deletion ButtonPaginationBehavior?

Deletion behaviour

token CancellationToken

A custom cancellation token that can be cancelled at any point.

Returns

Task

Remarks

This is the "default" overload for SendPaginatedMessageAsync, and will use buttons. Feel free to specify default(PaginationEmojis) to use reactions and emojis specified in InteractivityConfiguration, instead.

SendPaginatedMessageAsync(DiscordChannel, DiscordUser, IEnumerable<Page>, TimeSpan?, PaginationBehaviour?, ButtonPaginationBehavior?)

Sends a paginated message with buttons.

public Task SendPaginatedMessageAsync(DiscordChannel channel, DiscordUser user, IEnumerable<Page> pages, TimeSpan? timeoutoverride, PaginationBehaviour? behaviour = null, ButtonPaginationBehavior? deletion = null)

Parameters

channel DiscordChannel

The channel to send it on.

user DiscordUser

User to give control.

pages IEnumerable<Page>

The pages.

timeoutoverride TimeSpan?

Override timeout period.

behaviour PaginationBehaviour?

Pagination behaviour.

deletion ButtonPaginationBehavior?

Deletion behaviour

Returns

Task

Remarks

This is the "default" overload for SendPaginatedMessageAsync, and will use buttons. Feel free to specify default(PaginationEmojis) to use reactions and emojis specified in InteractivityConfiguration, instead.

SendPaginatedMessageAsync(DiscordChannel, DiscordUser, IEnumerable<Page>, PaginationEmojis, PaginationBehaviour?, PaginationDeletion?, TimeSpan?)

Sends a paginated message. For this Event you need the GuildMessageReactions intent specified in Intents

public Task SendPaginatedMessageAsync(DiscordChannel channel, DiscordUser user, IEnumerable<Page> pages, PaginationEmojis emojis, PaginationBehaviour? behaviour = null, PaginationDeletion? deletion = null, TimeSpan? timeoutoverride = null)

Parameters

channel DiscordChannel

Channel to send paginated message in.

user DiscordUser

User to give control.

pages IEnumerable<Page>

Pages.

emojis PaginationEmojis

Pagination emojis.

behaviour PaginationBehaviour?

Pagination behaviour (when hitting max and min indices).

deletion PaginationDeletion?

Deletion behaviour.

timeoutoverride TimeSpan?

Override timeout period.

Returns

Task