ActiveReports 12
FormatNumber Method

GrapeCity.ActiveReports.v12 Assembly > GrapeCity.Enterprise.Data.VisualBasicReplacement Namespace > Strings Class : FormatNumber Method
Required. Expression to be formatted.
Optional. Numeric value indicating how many places are displayed to the right of the decimal. The default value is –1, which indicates that the computer's regional settings are used.
Optional. TriState constant that indicates whether a leading 0 is displayed for fractional values. See "Settings" for values.
Optional. TriState constant that indicates whether to place negative values within parentheses. See "Settings" for values.
Optional. TriState constant that indicates whether or not numbers are grouped using the group delimiter specified in the locale settings. See "Settings" for values.
Returns an expression formatted as a number.
Syntax
'Declaration
 
Public Shared Function FormatNumber( _
   ByVal expression As Object, _
   Optional ByVal numDigitsAfterDecimal As Integer, _
   Optional ByVal includeLeadingDigit As TriState, _
   Optional ByVal useParensForNegativeNumbers As TriState, _
   Optional ByVal groupDigits As TriState _
) As String

Parameters

expression
Required. Expression to be formatted.
numDigitsAfterDecimal
Optional. Numeric value indicating how many places are displayed to the right of the decimal. The default value is –1, which indicates that the computer's regional settings are used.
includeLeadingDigit
Optional. TriState constant that indicates whether a leading 0 is displayed for fractional values. See "Settings" for values.
useParensForNegativeNumbers
Optional. TriState constant that indicates whether to place negative values within parentheses. See "Settings" for values.
groupDigits
Optional. TriState constant that indicates whether or not numbers are grouped using the group delimiter specified in the locale settings. See "Settings" for values.

Return Value

Returns an expression formatted as a number.
See Also

Reference

Strings Class
Strings Members