Conversions.ToDecimal Method

Definition

Converts specified object to a Decimal value.

Overloads

ToDecimal(Boolean)

Converts a Boolean value to a Decimal value.

ToDecimal(Object)

Converts an object to a Decimal value.

ToDecimal(String)

Converts a string to a Decimal value.

ToDecimal(Boolean)

Source:
Conversions.vb
Source:
Conversions.vb
Source:
Conversions.vb

Converts a Boolean value to a Decimal value.

public:
 static System::Decimal ToDecimal(bool Value);
public static decimal ToDecimal (bool Value);
static member ToDecimal : bool -> decimal
Public Shared Function ToDecimal (Value As Boolean) As Decimal

Parameters

Value
Boolean

A Boolean value to convert.

Returns

The Decimal value of the Boolean value.

Applies to

ToDecimal(Object)

Source:
Conversions.vb
Source:
Conversions.vb
Source:
Conversions.vb

Converts an object to a Decimal value.

public:
 static System::Decimal ToDecimal(System::Object ^ Value);
public static decimal ToDecimal (object Value);
public static decimal ToDecimal (object? Value);
static member ToDecimal : obj -> decimal
Public Shared Function ToDecimal (Value As Object) As Decimal

Parameters

Value
Object

The object to convert.

Returns

The Decimal value of the object.

Applies to

ToDecimal(String)

Source:
Conversions.vb
Source:
Conversions.vb
Source:
Conversions.vb

Converts a string to a Decimal value.

public:
 static System::Decimal ToDecimal(System::String ^ Value);
public static decimal ToDecimal (string Value);
public static decimal ToDecimal (string? Value);
static member ToDecimal : string -> decimal
Public Shared Function ToDecimal (Value As String) As Decimal

Parameters

Value
String

The string to convert.

Returns

The Decimal value of the string.

Applies to