Click or drag to resize

Button   Conversion (Button to Boolean)

Allow the user to convert the button to a boolean value to see if it's pressed or not. Provides an easier way to program without the need to check the enum.

Namespace: Crestron.SimplSharpPro.DeviceSupport
Assembly: SimplSharpPro (in SimplSharpPro.dll) Version: 2.21.121
Syntax
C#
public static implicit operator bool (
	Button b
)

Parameters

b  Button
Button being used.

Return Value

Boolean
False if the button state is NA or Released, otherwise true

Version Information

.NET

Supported in: 6.0

.NET Compact Framework

Supported in: 3.5
See Also