Table of Contents

Class TablistDialog

Namespace
SampSharp.Entities.SAMP
Assembly
SampSharp.OpenMp.Entities.dll

Represents a dialog with a list of selectable rows with columns.

public class TablistDialog : IDialog<TablistDialogResponse>, IDialog, IEnumerable<TablistDialogRow>, IEnumerable
Inheritance
TablistDialog
Implements
Inherited Members

Constructors

TablistDialog(string?, string?, string?, int)

Initializes a new instance of the TablistDialog class.

public TablistDialog(string? caption, string? button1, string? button2, int columnCount)

Parameters

caption string

The caption.

button1 string

The text on the left button.

button2 string

The text on the right button. If the value is null, the right button is hidden.

columnCount int

The number of columns in this dialog.

TablistDialog(string?, string?, string?, string)

Initializes a new instance of the TablistDialog class.

public TablistDialog(string? caption, string? button1, string? button2, string columnHeader1)

Parameters

caption string

The caption.

button1 string

The text on the left button.

button2 string

The text on the right button. If the value is null, the right button is hidden.

columnHeader1 string

The first column header.

TablistDialog(string?, string?, string?, string, string)

Initializes a new instance of the TablistDialog class.

public TablistDialog(string? caption, string? button1, string? button2, string columnHeader1, string columnHeader2)

Parameters

caption string

The caption.

button1 string

The text on the left button.

button2 string

The text on the right button. If the value is null, the right button is hidden.

columnHeader1 string

The first column header.

columnHeader2 string

The second column header.

TablistDialog(string?, string?, string?, string, string, string)

Initializes a new instance of the TablistDialog class.

public TablistDialog(string? caption, string? button1, string? button2, string columnHeader1, string columnHeader2, string columnHeader3)

Parameters

caption string

The caption.

button1 string

The text on the left button.

button2 string

The text on the right button. If the value is null, the right button is hidden.

columnHeader1 string

The first column header.

columnHeader2 string

The second column header.

columnHeader3 string

The third column header.

TablistDialog(string, string, string, string, string, string, string)

Initializes a new instance of the TablistDialog class.

public TablistDialog(string caption, string button1, string button2, string columnHeader1, string columnHeader2, string columnHeader3, string columnHeader4)

Parameters

caption string

The caption.

button1 string

The text on the left button.

button2 string

The text on the right button. If the value is null, the right button is hidden.

columnHeader1 string

The first column header.

columnHeader2 string

The second column header.

columnHeader3 string

The third column header.

columnHeader4 string

The third column header.

TablistDialog(string?, string?, string?, string[])

Initializes a new instance of the TablistDialog class.

public TablistDialog(string? caption, string? button1, string? button2, string[] columnHeaders)

Parameters

caption string

The caption.

button1 string

The text on the left button.

button2 string

The text on the right button. If the value is null, the right button is hidden.

columnHeaders string[]

The column headers.

Properties

Button1

Gets or sets the text on the left button of this tablist dialog.

public string? Button1 { get; set; }

Property Value

string

Button2

Gets or sets the text on the right button of this tablist dialog. If the value is null, the right button is hidden.

public string? Button2 { get; set; }

Property Value

string

Caption

Gets or sets the caption of this tablist dialog.

public string? Caption { get; set; }

Property Value

string

ColumnCount

Gets the number of columns in this tablist dialog.

public int ColumnCount { get; }

Property Value

int

Header

Gets or sets the header of this tablist dialog.

public TablistDialogRow? Header { get; set; }

Property Value

TablistDialogRow

Rows

Gets the rows of this dialog.

public TablistDialogRowCollection Rows { get; }

Property Value

TablistDialogRowCollection

Methods

Add(TablistDialogRow)

Adds the specified row to the list.

public void Add(TablistDialogRow row)

Parameters

row TablistDialogRow

The row to add.

Exceptions

ArgumentNullException

Thrown if row is null.

Add(params string[])

Adds a row to the list with the specified columns.

public void Add(params string[] columns)

Parameters

columns string[]

The columns of the row to add.

Exceptions

ArgumentNullException

Thrown if columns is null.

Add(string[], object)

Adds a row to the list with the specified columns and tag.

public void Add(string[] columns, object tag)

Parameters

columns string[]

The columns of the row to add.

tag object

The tag of the row to add. The tag can be used so associate data with this row which can be used retrieved when the user responds to the dialog.

Exceptions

ArgumentNullException

Thrown if columns is null.

GetEnumerator()

Returns an enumerator that iterates through the rows of this tablist dialog.

public IEnumerator<TablistDialogRow> GetEnumerator()

Returns

IEnumerator<TablistDialogRow>

The enumerator that can be used to iterate through the rows of this tablist dialog.