Jump to content
Software FX Community

Number Percision Display Problem


User (Legacy)

Recommended Posts

I make graphs by passing in double values to the X and Y.  When the graph is

drawn it looks correct. But when I hover over a datapoint that is not on an

integer value (over the X axis) it displays a truncated integer value for

the X anyway. The data editor also only has integers in there. (see

attached picture). How do I make the graph automaticaly recongnize my data

format and show me the right percision.

I tried to use the Decimals property of the X axis to display the percision,

but that wasn't a valid solution. If the numbers are integers, I don't want

to see decimal places with zeros. And the axis labels shouldn't have the

.00 after it if it falls on an integer.

pAxis->Decimals = 2;

I also tried to specify the Format, using AF_NONE and when that didn't help,

AF_NUMBER which also didn't do anything.

CComVariant var = AF_NONE;

pAxis->Format = var;

So is there a way to do what I need? Thanks for your help in advance.

Diana Tetelman

dtetelman@stk.com

Link to comment
Share on other sites

I have tried that but the problem is that even when the numbers are integers

(like the labels on the axis) they are still displayed with XXX.00 on end

and that is not acceptable for our customer and they are complaining. Is

there a way to have integers on the axis labels but true data on the actual

data points?

Thanks for your help,

Diana

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

news:wvvF6omNDHA.3180@webserver1.softwarefx.com...

> pAxis->Decimals = 2;

>

>

> Will do it if pAxis is the X-Axis.

>

> --

> FP

> Software FX, Inc.

>

>

Link to comment
Share on other sites

Different formatting for axis labels and Point Labels (including tooltips

and Data Editor) is not supported in Chart FX 5.x this is a new feature in

Chart FX 6 (for .NET).

You can capture the GetAxisLabel event to customize your axis labels, this

will allow you to have 0 decimals in the axis while having 2 decimals in the

data editor, point labels and tooltips.

About displaying 1.00 as "1" while at the same time displaying 1.5 as "1.5",

this is also a new feature in Chart FX 6 (for .NET). Newly available formats

allow you to achieve this functionality.

Notice that the data itself is never rounded, data is kept as a Double

precision floating point number, it is only rounded for display purposes

using the specified axis format.

--

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...