menu

ASP.NET Web Forms

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class ToggleButtonPropertiesBuilder

    Show / Hide Table of Contents

    Class ToggleButtonPropertiesBuilder

    Inheritance
    System.Object
    ToggleButtonPropertiesBuilder
    Implements
    IPropertiesBuilder
    System.Web.IHtmlString
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Syncfusion.JavaScript
    Assembly: Syncfusion.EJ.dll
    Syntax
    public class ToggleButtonPropertiesBuilder : IPropertiesBuilder, IHtmlString

    Constructors

    ToggleButtonPropertiesBuilder()

    Initializes a new instance of the ToggleButtonPropertiesBuilder class.

    Declaration
    public ToggleButtonPropertiesBuilder()

    ToggleButtonPropertiesBuilder(ToggleButton)

    Initializes a new instance of the ToggleButtonPropertiesBuilder class by the specified toggle button object.

    Declaration
    public ToggleButtonPropertiesBuilder(ToggleButton togglebutton)
    Parameters
    Type Name Description
    ToggleButton togglebutton

    Fields

    togglebutton

    Specifies the instance of the ToggleButton class.

    Declaration
    public ToggleButton togglebutton
    Field Value
    Type Description
    ToggleButton

    Methods

    ActivePrefixIcon(String)

    Specifies the primary icon of toggle button when the control is in active(checked) state. This is applicable for the content types image only, image text image, text and image and image both.

    Declaration
    public ToggleButtonPropertiesBuilder ActivePrefixIcon(string activePrefixIcon)
    Parameters
    Type Name Description
    System.String activePrefixIcon
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ActiveSuffixIcon(String)

    Specifies the secondary icon of toggle button when the control is in active(checked) state. This is applicable for the content types imagetextimage and imageboth.

    Declaration
    public ToggleButtonPropertiesBuilder ActiveSuffixIcon(string activeSuffixIcon)
    Parameters
    Type Name Description
    System.String activeSuffixIcon
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ActiveText(String)

    Specifies the text to be shown in the active(checked) state of the toggle button.

    Declaration
    public ToggleButtonPropertiesBuilder ActiveText(string activeText)
    Parameters
    Type Name Description
    System.String activeText
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ClientSideEvents(Action<ToggleButtonClientSideEventsBuilder>)

    Specifies to trigger the toggle button client side events.

    Declaration
    public ToggleButtonPropertiesBuilder ClientSideEvents(Action<ToggleButtonClientSideEventsBuilder> clientSideEvents)
    Parameters
    Type Name Description
    System.Action<ToggleButtonClientSideEventsBuilder> clientSideEvents
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ContentType(ContentType)

    Specifies the content type of the toggle button. Content type can be image only, text only, image text image, text and image or image both.

    Declaration
    public ToggleButtonPropertiesBuilder ContentType(ContentType contentType)
    Parameters
    Type Name Description
    ContentType contentType
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    CssClass(String)

    Specifies the root CSS class to button for theme customization with specified string argument.

    Declaration
    public ToggleButtonPropertiesBuilder CssClass(string cssClass)
    Parameters
    Type Name Description
    System.String cssClass
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    DefaultPrefixIcon(String)

    Specifies the primary icon of toggle button when the control is in default(unchecked) state. This is applicable for the content types image only, image text image, text and image and image both.

    Declaration
    public ToggleButtonPropertiesBuilder DefaultPrefixIcon(string defaultPrefixIcon)
    Parameters
    Type Name Description
    System.String defaultPrefixIcon
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    DefaultSuffixIcon(String)

    Specifies the secondary icon of toggle button when the control is in default(unchecked) state. This is applicable for the content types imagetextimage and imageboth.

    Declaration
    public ToggleButtonPropertiesBuilder DefaultSuffixIcon(string defaultSuffixIcon)
    Parameters
    Type Name Description
    System.String defaultSuffixIcon
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    DefaultText(String)

    Specifies the text to be shown in the default(unchecked) state of the toggle button.

    Declaration
    public ToggleButtonPropertiesBuilder DefaultText(string defaultText)
    Parameters
    Type Name Description
    System.String defaultText
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Enabled()

    Specifies the toggle button to respond for user interaction.

    Declaration
    public ToggleButtonPropertiesBuilder Enabled()
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Enabled(Boolean)

    Specifies the toggle button to respond for user interaction with specified boolean argument.

    Declaration
    public ToggleButtonPropertiesBuilder Enabled(bool enabled)
    Parameters
    Type Name Description
    System.Boolean enabled
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    EnablePersistence()

    Specifies to sustain the toggle button model value even after form post back/browser refresh.

    Declaration
    public ToggleButtonPropertiesBuilder EnablePersistence()
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    EnablePersistence(Boolean)

    Specifies to sustain the toggle button model value even after form post back/browser refresh by the specified boolean argument.

    Declaration
    public ToggleButtonPropertiesBuilder EnablePersistence(bool persist)
    Parameters
    Type Name Description
    System.Boolean persist
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    EnableRTL()

    Specifies to align the toggle button control in right to left direction.

    Declaration
    public ToggleButtonPropertiesBuilder EnableRTL()
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    EnableRTL(Boolean)

    Specifies to align the toggle button control in right to left direction with specified boolean argument.

    Declaration
    public ToggleButtonPropertiesBuilder EnableRTL(bool rtl)
    Parameters
    Type Name Description
    System.Boolean rtl
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Height(String)

    Specifies the height of the toggle button.

    Declaration
    public ToggleButtonPropertiesBuilder Height(string height)
    Parameters
    Type Name Description
    System.String height
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    HtmlAttributes(IDictionary<String, Object>)

    Specifies to map the field of HTML attributes.

    Declaration
    public ToggleButtonPropertiesBuilder HtmlAttributes(IDictionary<string, object> itemHtmlAttributes)
    Parameters
    Type Name Description
    System.Collections.Generic.IDictionary<System.String, System.Object> itemHtmlAttributes
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ImagePosition(ImagePosition)

    Specifies the image position of the toggle button. Image position can be left or right and is applicable if content type is text and image.

    Declaration
    public ToggleButtonPropertiesBuilder ImagePosition(ImagePosition imagePosition)
    Parameters
    Type Name Description
    ImagePosition imagePosition
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    PreventToggle()

    Specifies to prevent the toggling behavior of the control.

    Declaration
    public ToggleButtonPropertiesBuilder PreventToggle()
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    PreventToggle(Boolean)

    Specifies to prevent the toggling behavior of the control with specified boolean argument.

    Declaration
    public ToggleButtonPropertiesBuilder PreventToggle(bool preventToggle)
    Parameters
    Type Name Description
    System.Boolean preventToggle
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Render()

    Renders the toggle button instance.

    Declaration
    public void Render()

    ShowRoundedCorner()

    Specifies the toggle button with rounded corners.

    Declaration
    public ToggleButtonPropertiesBuilder ShowRoundedCorner()
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ShowRoundedCorner(Boolean)

    Specifies the toggle button with rounded corners by the specified boolean argument.

    Declaration
    public ToggleButtonPropertiesBuilder ShowRoundedCorner(bool roundedCorner)
    Parameters
    Type Name Description
    System.Boolean roundedCorner
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Size(ButtonSize)

    Specifies the size of the toggle button. Size can be normal, mini, small, medium or large.

    Declaration
    public ToggleButtonPropertiesBuilder Size(ButtonSize size)
    Parameters
    Type Name Description
    ButtonSize size
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ToggleState()

    Specifies the toggling behavior of the control, when button is clicked.

    Declaration
    public ToggleButtonPropertiesBuilder ToggleState()
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ToggleState(Boolean)

    Specifies whether the control acts as a button or toggle button with the specified boolean argument.

    Declaration
    public ToggleButtonPropertiesBuilder ToggleState(bool checkedStatus)
    Parameters
    Type Name Description
    System.Boolean checkedStatus
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    ToHtmlString()

    Represents an HTML-encoded string.

    Declaration
    public string ToHtmlString()
    Returns
    Type Description
    System.String

    Type(ButtonType)

    Specifies the type of the toggle button. Type can be submit, reset or button.

    Declaration
    public ToggleButtonPropertiesBuilder Type(ButtonType type)
    Parameters
    Type Name Description
    ButtonType type
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Width(String)

    Specifies the width of the toggle button.

    Declaration
    public ToggleButtonPropertiesBuilder Width(string width)
    Parameters
    Type Name Description
    System.String width
    Returns
    Type Description
    ToggleButtonPropertiesBuilder

    Implements

    IPropertiesBuilder
    System.Web.IHtmlString
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved