StringExtensions.AsDecimal Metoda

Definice

Přetížení

AsDecimal(String)

Převede řetězec na Decimal číslo.

AsDecimal(String, Decimal)

Převede řetězec na Decimal číslo a určí výchozí hodnotu.

AsDecimal(String)

Převede řetězec na Decimal číslo.

public static decimal AsDecimal (this string value);
static member AsDecimal : string -> decimal
<Extension()>
Public Function AsDecimal (value As String) As Decimal

Parametry

value
String

Hodnota, kterou chcete převést.

Návraty

Převedená hodnota

Platí pro

AsDecimal(String, Decimal)

Převede řetězec na Decimal číslo a určí výchozí hodnotu.

public static decimal AsDecimal (this string value, decimal defaultValue);
static member AsDecimal : string * decimal -> decimal
<Extension()>
Public Function AsDecimal (value As String, defaultValue As Decimal) As Decimal

Parametry

value
String

Hodnota, kterou chcete převést.

defaultValue
Decimal

Hodnota, která se má vrátit, pokud value je null nebo neplatná.

Návraty

Převedená hodnota

Platí pro