Rediger

Del via


FormatterConverter.ToByte(Object) Method

Definition

Converts a value to an 8-bit unsigned integer.

public:
 virtual System::Byte ToByte(System::Object ^ value);
public byte ToByte (object value);
abstract member ToByte : obj -> byte
override this.ToByte : obj -> byte
Public Function ToByte (value As Object) As Byte

Parameters

value
Object

The object to convert.

Returns

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

Implements

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.ToByte method instead. For more information, see Byte, Convert and ValueType.

Applies to