Επεξεργασία

Κοινή χρήση μέσω


FormatterConverter.ToUInt16(Object) Method

Definition

Important

This API is not CLS-compliant.

Converts a value to a 16-bit unsigned integer.

public:
 virtual System::UInt16 ToUInt16(System::Object ^ value);
[System.CLSCompliant(false)]
public ushort ToUInt16 (object value);
[<System.CLSCompliant(false)>]
abstract member ToUInt16 : obj -> uint16
override this.ToUInt16 : obj -> uint16
Public Function ToUInt16 (value As Object) As UShort

Parameters

value
Object

The object to convert.

Returns

The converted value or null if the type parameter is null.

Implements

Attributes

Exceptions

The value parameter is null.

Remarks

This method uses the invariant culture (see CultureInfo.InvariantCulture). To use the current culture or to specify a culture, use the Convert.ToUInt16 method instead. For more information, see UInt16, Convert, and ValueType.

Applies to