Strings.FormatPercent メソッド
アセンブリ: Microsoft.VisualBasic (microsoft.visualbasic.dll 内)

Public Shared Function FormatPercent ( _ Expression As Object, _ <OptionalAttribute> Optional NumDigitsAfterDecimal As Integer = -1, _ <OptionalAttribute> Optional IncludeLeadingDigit As TriState = TriState.UseDefault, _ <OptionalAttribute> Optional UseParensForNegativeNumbers As TriState = TriState.UseDefault, _ <OptionalAttribute> Optional GroupDigits As TriState = TriState.UseDefault _ ) As String
Dim Expression As Object Dim NumDigitsAfterDecimal As Integer Dim IncludeLeadingDigit As TriState Dim UseParensForNegativeNumbers As TriState Dim GroupDigits As TriState Dim returnValue As String returnValue = Strings.FormatPercent(Expression, NumDigitsAfterDecimal, IncludeLeadingDigit, UseParensForNegativeNumbers, GroupDigits)
public static string FormatPercent ( Object Expression, [OptionalAttribute] int NumDigitsAfterDecimal, [OptionalAttribute] TriState IncludeLeadingDigit, [OptionalAttribute] TriState UseParensForNegativeNumbers, [OptionalAttribute] TriState GroupDigits )
public: static String^ FormatPercent ( Object^ Expression, [OptionalAttribute] int NumDigitsAfterDecimal, [OptionalAttribute] TriState IncludeLeadingDigit, [OptionalAttribute] TriState UseParensForNegativeNumbers, [OptionalAttribute] TriState GroupDigits )
public static String FormatPercent ( Object Expression, /** @attribute OptionalAttribute() */ int NumDigitsAfterDecimal, /** @attribute OptionalAttribute() */ TriState IncludeLeadingDigit, /** @attribute OptionalAttribute() */ TriState UseParensForNegativeNumbers, /** @attribute OptionalAttribute() */ TriState GroupDigits )
public static function FormatPercent ( Expression : Object, NumDigitsAfterDecimal : int, IncludeLeadingDigit : TriState, UseParensForNegativeNumbers : TriState, GroupDigits : TriState ) : String
戻り値
末尾にパーセント記号の付加されたパーセント形式 (100 で乗算した) として書式設定された式を返します。

詳細については、Visual Basic のトピック「FormatPercent 関数 (Visual Basic)」を参照してください。
1 つ以上のオプション引数が省略された場合、省略された引数の値はロケール設定によって提供されます。
![]() |
---|
設定情報はすべてアプリケーションのロケールから提供されます。既定では、コントロール パネルのロケール セットになります。これは、.NET Framework を使ってプログラムで変更できます。 |
IncludeLeadingDigit、UseParensForNegativeNumbers、および GroupDigits の各引数には次の設定があります。


Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Strings クラス
Strings メンバ
Microsoft.VisualBasic 名前空間
InvalidCastException
その他の技術情報
FormatPercent 関数 (Visual Basic)
文字列操作の概要
FormatCurrency 関数 (Visual Basic)
FormatDateTime 関数 (Visual Basic)
FormatNumber 関数 (Visual Basic)
TriState 列挙型
Weblioに収録されているすべての辞書からStrings.FormatPercent メソッドを検索する場合は、下記のリンクをクリックしてください。

- Strings.FormatPercent メソッドのページへのリンク