Quantcast
Channel: Rainmeter Forums
Viewing all articles
Browse latest Browse all 1540

Feeds & Internet Data • Re: Market Prices

$
0
0
2. Why don't I see a "," for prices over 1,000? (i.e. 12,995 versus 12995)
That was me forgetting to add formatting for the prices coming from the common .xml file. That's fixed in the latest version of Market Prices posted on Deviant Art.
1. Why do some of the prices and changes display 3 decimal places while most display only 2?
The prices are presented to two decimal places by default. However, the skin presents the Price Changes using the same string that is returned by CNBC.com. While most are to two decimal places there are some exceptions for the price change of stuff like crypto currencies which sometimes only change at 6-7 decimal places (see Shiba price changes below).
with commas.jpg
....(tried adding the NumOfDecimals=2 to each stock in "MoreThanOne.inc" but that had no effect.)
If you want to change the decimal places for the Price for Stock 3 go to [LabelPrice_3] in MoreThanOne.inc and change the digit '2' in format_price( [&mIndex3_Price] , 2 )

Code:

[LabelPrice_3]Meter=STRINGMeterStyle= sTextRight | sColorSetGrayx=#Col2XPos#Text=[&mFormatPriceScript:format_price( [&mIndex3_Price] , 2 )]
To change the decimal places for the Percentage Price Change of Stock 3 go to [LabelIndex3_ChangePer] and change the digit '2" at the end of [mIndex3_ChangePer:/1, 2 ]

Code:

[LabelIndex3_ChangePer]Meter=STRINGMeterStyle=sTextRight FontColor=#ColorSteady#x=#Col5XPos#Text=([mIndex3_ChangePer:/1,2]%)

Statistics: Posted by Mordasius — Today, 5:57 am



Viewing all articles
Browse latest Browse all 1540

Trending Articles