UISwitch.SetState(Boolean, Boolean) UISwitch.SetState(Boolean, Boolean) Method

Definition

This method changes the state of the switch, and will animate the change if specified.

[Foundation.Export("setOn:animated:")]
public virtual void SetState (bool newState, bool animated);
abstract member SetState : bool * bool -> unit
override this.SetState : bool * bool -> unit

Parameters

newState
Boolean Boolean

The new value of the switch.

animated
Boolean Boolean

If the change in state should be animated.

Applies to