NumberFormatInfo.CurrencyPositivePattern 屬性

定義

取得或設定正數貨幣值的格式模式。

public:
 property int CurrencyPositivePattern { int get(); void set(int value); };
public int CurrencyPositivePattern { get; set; }
member this.CurrencyPositivePattern : int with get, set
Public Property CurrencyPositivePattern As Integer

屬性值

正數貨幣值的格式模式。 InvariantInfo 的預設值為 0,代表 "$n",其中 "$" 為 CurrencySymbol,而 n 為數值。

例外狀況

屬性已設定為小於 0 或大於 3 的值。

正在設定屬性,而且 NumberFormatInfo 物件為唯讀。

備註

屬性 CurrencyPositivePattern 會與 「C」 標準格式字串搭配使用,以定義正貨幣值的模式。 如需詳細資訊,請參閱標準數值格式字串。 這個屬性具有下表中的其中一個值。 符號 「$」 是 CurrencySymbol ,而且 n 是數位。

相關聯的模式
0 $n
1 n$
2 $ n
3 n $

請注意,模式不支援正負號。

適用於

另請參閱