Sets a switch device name to a specified value. If the device name cannot be set by the application this must return the MethodNotImplementedException .

Namespace: ASCOM.DriverAccess
Assembly: ASCOM.DriverAccess (in ASCOM.DriverAccess.dll) Version: 6.0.0.0 (6.1.1.2619)

Syntax

C#
public void SetSwitchName(
	short id,
	string name
)
Visual Basic
Public Sub SetSwitchName ( _
	id As Short, _
	name As String _
)
Visual C++
public:
virtual void SetSwitchName(
	short id, 
	String^ name
) sealed

Parameters

id
Type: System..::..Int16
The number of the device whose name is to be set
name
Type: System..::..String
The name of the device

Implements

ISwitchV2..::..SetSwitchName(Int16, String)

Exceptions

ExceptionCondition
ASCOM..::..MethodNotImplementedExceptionIf the device name cannot be set in the application code.
ASCOM..::..InvalidValueExceptionIf id is outside the range 0 to MaxSwitch - 1

See Also