Jump to content
Software FX Community

Y-Axis format mask not working correctly.


User (Legacy)

Recommended Posts

I am applying a format mask to the Y-Axis of my chart as follows:

ChartFx1.Axis(ChartfxLib.CfxAxisIndex.AXIS_Y).Format =

"#,##0,.00;(#,##0,.00)"

According to the API Help file a trialling comma should divide the cause

1000.0 to be displayed as 1.00. The first comma should delimit thousands so

that 1000000.0 would be displayed 1,000,000.00. The combined result should

be 1,000.00 representing 1 million. But my chart is displaying 1000000.00

and seems to be completely ignoring the commas within the format mask.

Why is this?

Regards, Nick

Link to comment
Share on other sites

If you read my first posting you will see that this is intentional. According to the ChartFX API help file this is correct:

, Thousand separator.

The thousand separator separates thousands from hundreds within a number that has four or more places to the left of the decimal separator. Standard use of the thousand separator is specified if the format contains a comma surrounded by digit placeholders (0 or #). Two adjacent commas or a comma immediately to the left of the decimal separator (whether or not a decimal is specified) means "scale the number by dividing it by 1000, rounding as needed." You can scale large numbers using this technique. For example, you can use the format string "##0,," to represent 100 million as 100. Numbers smaller than 1 million are displayed as 0. Two adjacent commas in any position other than immediately to the left of the decimal separator are treated simply as specifying the use of a thousand separator. The actual character used as the thousand separator in the formatted output depends on the Number Format specified in the International section of the Control Panel. For some countries, a period is used as the thousand separator.

Is this not the case or is this a bug...

"SoftwareFX Support" <support@softwarefx.com> wrote in message news:AijScDnDCHA.1372@webserver1.softwarefx.com...

> There is an extra Comma here, it should be:

>

> ChartFx1.Axis(ChartfxLib.CfxAxisIndex.AXIS_Y).Format = "#,##0.00;(#,##0.00)"

>

>

> --

> FP

> Software FX, Inc.

>

>

Link to comment
Share on other sites

Why is that SoftwareFX is not treating this as a bug. The software should do

what the documentation says it does, any deviation is a bug by definition.

I have looked at the scale property and there seems no way to actually

achieve what you are suggesting. Kindly provide a work example to

demonstrate what on earth you mean.

Regards

Nick, PMG

"SoftwareFX Support" <support@softwarefx.com> wrote in message

news:CU9kh8KECHA.1324@webserver1.softwarefx.com...

> This is incorrect in the docs, to divide by 1000 use the Scale property in

> the Axis object.

>

> --

> FP

> Software FX, Inc.

>

>

Link to comment
Share on other sites

I assume you mean the ScaleUnit property.

This is now working correctly. But the thousands separator is not. I assume

that this is because it cannot handle the comma next to the decimal point.

"SoftwareFX Support" <support@softwarefx.com> wrote in message

news:CU9kh8KECHA.1324@webserver1.softwarefx.com...

> This is incorrect in the docs, to divide by 1000 use the Scale property in

> the Axis object.

>

> --

> FP

> Software FX, Inc.

>

>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...