CURRENCYFMT Structure

Type CURRENCYFMT
	NumDigits As Long
	LeadingZero As Long
	Grouping As Long
	lpDecimalSep As String
	lpThousandSep As String
	NegativeOrder As Long
	PositiveOrder As Long
	lpCurrencySymbol As String
End Type

Description & Usage

The CURRENCYFMT structure stores information about how to format a currency value for display. This structure allows a program to specify how it wants currency to be displayed, overriding the format used by a locale.

Visual Basic-Specific Issues

None.

Data Members

NumDigits
The number of digits to display after the decimal point.
LeadingZero
If zero, do not pad the space to the right of the decimal point with zeros if there are fewer fractional digits than specified by NumDigits. If nonzero, then do pad the space. For example, if NumDigits is 3 and the number to display is $1.23, setting this data member to zero displays the number as "$1.23". Setting this data member to any other value displays "$1.230".
Grouping
The number of digits to include in each group to the left of the decimal point. Typically, groups of three are used (e.g., $1,234,567). Values in the range of 0-9 are valid.
lpDecimalSep
The character to use for the decimal point.
lpThousandSep
The character to use for the grouping separator.
NegativeOrder
One of the following values specifying how to represent a negative currency value. An example of each choice is shown in the following list for the value of negative $1.1.
0
($1.1)
1
-$1.1
2
$-1.1
3
$1.1-
4
(1.1$)
5
-1.1$
6
1.1-$
7
1.1$-
8
-1.1 $ (space before $)
9
-$ 1.1 (space after $)
10
1.1 $- (space before $)
11
$ 1.1- (space after $)
12
$ -1.1 (space after $)
13
1.1- $ (space before $)
14
($ 1.1) (space after $)
15
(1.1 $) (space before $)
PositiveOrder
One of the following values specifying how to display a positive currency value. An example of each choice is shown in the following list for the value of $1.1.
0
$1.1
1
1.1$
2
$ 1.1 (space after $)
3
1.1 $ (space before $)
lpCurrencySymbol
The symbol used to represent the currency. For example, US dollars are typically represented by the $ character.

Used By

GetCurrencyFormat

Back to the Structure list.
Back to the Reference section.


Last Modified: April 16, 2000
This page is copyright © 2000 Paul Kuliniewicz. Copyright Information Revised October 29, 2000
Go back to the Windows API Guide home page.
E-mail: vbapi@vbapi.com Send Encrypted E-Mail
This page is at http://www.vbapi.com/ref/n/currencyfmt.html