Login.LoginButtonType Property
Gets or sets the type of button to use when rendering the Login button.
Assembly: System.Web (in System.Web.dll)
abstract LoginButtonType : ButtonType with get, set override LoginButtonType : ButtonType with get, set
<asp:Login LoginButtonType="ButtonType" />
Property Value
Type: System.Web.UI.WebControls.ButtonTypeOne of the ButtonType enumeration values. The default is Button.
| Exception | Condition |
|---|---|
| ArgumentOutOfRangeException | The LoginButtonType property is not set to a valid ButtonType enumeration value. |
The LoginButtonType property determines the type of button to use for the Login control's login button. The following table describes the different button types.
LoginButtonType setting | Type of button rendered |
|---|---|
An HTML button with the text specified in the LoginButtonText property. | |
An image. The URL of the image is specified in the LoginButtonImageUrl property. The string specified in the LoginButtonText property is used as alternate text for the image. | |
An HTML link with the text specified in the LoginButtonText property. |
When the LoginButtonType property is set to Button or Link, the content of the LoginButtonImageUrl property is ignored.
The following code example shows the different types of login buttons available for the Login control.
Security Note |
|---|
This example contains a text box that accepts user input, which is a potential security threat. By default, ASP.NET Web pages validate that user input does not include script or HTML elements. For more information, see Script Exploits Overview. |
Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2
The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Security Note