For f.ex. line series I use "GetAxisLabels" event to modify labels. The same method does not seem to work for circular gauge series internal axis. Java version seems to have "AxisLabelResolver" and "AxisLabelAdapter" combo which can be used to do this (according to forum posts I found using forum search engine) but ActiveX API does not seem to have these methods.
Is there a way to modify circular gauge labels? The problem I have is that numerical values to be shown on gauge are very large (and the range is large too) so I'd like to modify them like 500 k, 50 M, 5 G and so on based on numerical value without the need to modify actual values.
Another problem. Using gauge.GetRanges().GetItems(0) etc. call seems to generate access violation fault or something similar. So I cannot add or modify ranges. I can only use GetGreenLine() and GetRedLine() function calls i.e. two ranges max.
Using latest 2016.0.0.2 release.
CircularGauge axis labels
Re: CircularGauge axis labels
Hello,
This comes from TeeChart VCL so I've added it to its public tracker:
http://bugs.teechart.net/show_bug.cgi?id=1634
This comes from TeeChart VCL so I've added it to its public tracker:
http://bugs.teechart.net/show_bug.cgi?id=1634
Note by default you have two Ranges (indexes 0 and 1), and you can add a third (index 2). Ie this works for me:Tero wrote:Another problem. Using gauge.GetRanges().GetItems(0) etc. call seems to generate access violation fault or something similar. So I cannot add or modify ranges. I can only use GetGreenLine() and GetRedLine() function calls i.e. two ranges max.
Code: Select all
TChart1.AddSeries scCircularGauge
With TChart1.Series(0).asCircularGauge
.Ranges.Items(0).EndValue = 50
.Ranges.Items(1).StartValue = 90
.Ranges.Add 60, 80, clTeeColor
With .Ranges.Items(2)
.Format.Gradient.StartColor = vbYellow
.Format.Gradient.EndColor = vbRed
End With
End With
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |
Re: CircularGauge axis labels
Using VS2012 C++ code line:
gauge.GetRanges().GetItems(0);
causes an access violation when InvokeHelper is called:
CGaugeRange CGaugeRanges::GetItems(long Index)
{
LPDISPATCH pDispatch;
static BYTE parms[] =
VTS_I4;
InvokeHelper(0xc9, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, parms,
Index);
return CGaugeRange(pDispatch);
}
gauge.GetRanges().GetItems(0);
causes an access violation when InvokeHelper is called:
CGaugeRange CGaugeRanges::GetItems(long Index)
{
LPDISPATCH pDispatch;
static BYTE parms[] =
VTS_I4;
InvokeHelper(0xc9, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, parms,
Index);
return CGaugeRange(pDispatch);
}
Re: CircularGauge axis labels
Another question. Is it possible to make axis labels drawn so that they are always inside face area not over axis area:
This does not look good!
This does not look good!
Re: CircularGauge axis labels
Hello,
I've added it to the public tracker:
http://bugs.teechart.net/show_bug.cgi?id=1635
http://bugs.teechart.net/show_bug.cgi?id=833
Please, open different threads for different issues.
I've reproduced that problem with VC++, while it seems to work fine in VB6.Tero wrote:Using VS2012 C++ code line:
gauge.GetRanges().GetItems(0);
causes an access violation when InvokeHelper is called:
I've added it to the public tracker:
http://bugs.teechart.net/show_bug.cgi?id=1635
It seems to be this issue:Tero wrote:Another question. Is it possible to make axis labels drawn so that they are always inside face area not over axis area:
http://bugs.teechart.net/show_bug.cgi?id=833
Please, open different threads for different issues.
Best Regards,
Yeray Alonso Development & Support Steema Software Av. Montilivi 33, 17003 Girona, Catalonia (SP) | |
Please read our Bug Fixing Policy |