Tab

ASPxButton.Image Property

Gets the settings of an image displayed within the button control.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v21.1.dll

Declaration

public CheckedButtonImageProperties Image { get; }

Property Value

Type Description
CheckedButtonImageProperties

A CheckedButtonImageProperties object that contains image settings.

Remarks

Use the Image property to specify the button’s image. The image position within the button is specified by the ASPxButton.ImagePosition property.

Online Demos

Example

The following examples illustrates how to use the Image property.

Web Forms:

<dx:ASPxButton ID="btnImageAndText" runat="server"
    Width="90px" Text="Cancel" AutoPostBack="false">
    <Image IconID="actions_cancel_16x16"></Image>
</dx:ASPxButton>

MVC:

@Html.DevExpress().Button(
    settings => {
        settings.Name = "btnImageAndText";
        settings.Width = 90;
        settings.Text = "Cancel";
        settings.Images.Image.IconID = IconID.ActionsCancel16x16;
}).GetHtml()
See Also