Skip to main content
Tab

GridViewCommandColumn.ShowDeleteButton Property

Specifies whether the Delete command button is displayed in the command column.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.2.dll

Declaration

[DefaultValue(false)]
public bool ShowDeleteButton { get; set; }

Property Value

Type Default Description
Boolean false

true, if the button is visible; otherwise, false.

Remarks

Use the ShowDeleteButton property to specify whether the Delete button is visible in the command column. The button settings can be customized using the ASPxGridViewCommandButtonSettings.DeleteButton property.

In markup:

<dx:ASPxGridView ID="ASPxGridView1" runat="server" >
    <Columns>  
        <dx:GridViewCommandColumn ShowDeleteButton="True" />  
        ...
    </Columns>  
</dx:ASPxGridView>

In code:

using DevExpress.Web;
...
protected void Page_Load(object sender, EventArgs e)  {
    ASPxGridView grid1 = new ASPxGridView();
    grid1.ID = "grid1";
    Page.Form.Controls.Add(grid1);
    ...
    GridViewCommandColumn commandColumn = new GridViewCommandColumn();
    commandColumn.ShowDeleteButton = true;
    grid1.Columns.Add(commandColumn);
    ...
}

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the ShowDeleteButton property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also