Back to Devexpress

ASPxButton.RenderMode Property

aspnet-devexpress-dot-web-dot-aspxbutton-004ce067.md

latest2.5 KB
Original Source

ASPxButton.RenderMode Property

Specifies whether the button is rendered as a button or as a link.

Namespace : DevExpress.Web

Assembly : DevExpress.Web.v25.2.dll

NuGet Package : DevExpress.Web

Declaration

csharp
[DefaultValue(ButtonRenderMode.Button)]
public ButtonRenderMode RenderMode { get; set; }
vb
<DefaultValue(ButtonRenderMode.Button)>
Public Property RenderMode As ButtonRenderMode

Property Value

TypeDefaultDescription
ButtonRenderModeButton

One of the ButtonRenderMode enumeration values.

|

Available values:

NameDescription
Button

The button is rendered as an input HTML element.

| | Link |

The button is rendered as a hyperlink HTML element.

| | Secondary |

Identifies a button of secondary importance.

| | Outline |

Represents the button with a colored border and without a background color.

| | Danger |

The button indicates a dangerous or potentially negative action.

|

Remarks

Use the RenderMode property to specify which element is used to render a button: a hyperlink (the Link value) or an input (the others values).

Use the Link mode to create a hyperlink-style button on the Web page. In this mode, the control looks like an ASPxHyperLink control and behaves like an ASPxButton control. If you want to link to another Web page when the control is clicked, use the ASPxHyperLink control.

The code samples below demonstrate a button’s ASP markup and the corresponding HTML code rendered for this button.

  • Button Render Mode

  • Link Render Mode

See Also

ASPxButton Class

ASPxButton Members

DevExpress.Web Namespace