Android Guides | Samples

Android.Widget.ToggleButton Class

Displays checked/unchecked states as a button with a "light" indicator and by default accompanied with the text "ON" or "OFF".

See Also: ToggleButton

Syntax

[Android.Runtime.Register("android/widget/ToggleButton", DoNotGenerateAcw=true)]
public class ToggleButton : CompoundButton

Remarks

Displays checked/unchecked states as a button with a "light" indicator and by default accompanied with the text "ON" or "OFF".

See the Toggle Buttons guide.

[Android Documentation]

Requirements

Namespace: Android.Widget
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1

The members of Android.Widget.ToggleButton are listed below.

See Also: CompoundButton

Public Constructors

Protected Constructors

A constructor used when creating managed representations of JNI objects; called by the runtime.

Public Properties

TextOffString.
TextOffFormattedICharSequence. Returns the text for when the button is not in the checked state.
TextOnString.
TextOnFormattedICharSequence. Returns the text for when the button is in the checked state.

Protected Properties

[read-only]
override
ThresholdClassIntPtr. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.
[read-only]
override
ThresholdTypeType. This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.