hello,
how can it be VerticalAxisCustom property cannot be changed?
I create a custom panel (returning 0 as custom panel ID) then I assign the
ID to the property but if I check the value of VerticalAxisCustom it's
still -1!
what's wrong?
nefis
VerticalAxisCustom property
Hi nefix,
which TeeChart Pro version are you using ?
It works fine using the TeeChart Pro v5.06 or above and the following code :
Josep Lluis Jorge
http://support.steema.com
which TeeChart Pro version are you using ?
It works fine using the TeeChart Pro v5.06 or above and the following code :
Code: Select all
Private Sub Form_Load()
With TChart1
.Aspect.View3D = False
.AddSeries scLine
.Series(0).FillSampleValues 20
.AddSeries scLine
.Series(1).FillSampleValues 20
.Axis.AddCustom False
.Axis.AddCustom True
.Series(0).HorizontalAxisCustom = 1
.Series(0).VerticalAxisCustom = 0
.Axis.Custom(0).PositionPercent = 30
.Axis.Custom(0).EndPosition = 60
.Axis.Custom(0).GridPen.Visible = False
.Axis.Custom(1).PositionPercent = 40
.Axis.Custom(1).StartPosition = 30
.Axis.Custom(1).GridPen.Visible = False
End With
End Sub
Private Sub Command1_Click()
MsgBox (TChart1.Series(0).VerticalAxisCustom)
End Sub
http://support.steema.com
Hello nefis,
There is no internal checking in the put or get of the TeeChart Series VerticalAxisCustom property that might cause this problem. -1 reports that TeeChart has been unable to locate a Vertical Custom Axis associated with this Series,
You mention you are adding a Custom Panel to get the index number to set, that's a Custom Axis, correct?
If you are using Visual Basic please check the difference between Josep Lluis's code and yours to localise the problem. If you are using VC++ you could open the VC++ 'TeeChart palette components' example and post this code into the OnButton2() method to see an example of the return value of the VerticalAxisCustom property in VC++.
If that doesn't help you locate the problem and you have some more information that might us help identify the problem please let us know.
Regards,
Marc Meumann
Steema Support
There is no internal checking in the put or get of the TeeChart Series VerticalAxisCustom property that might cause this problem. -1 reports that TeeChart has been unable to locate a Vertical Custom Axis associated with this Series,
You mention you are adding a Custom Panel to get the index number to set, that's a Custom Axis, correct?
If you are using Visual Basic please check the difference between Josep Lluis's code and yours to localise the problem. If you are using VC++ you could open the VC++ 'TeeChart palette components' example and post this code into the OnButton2() method to see an example of the return value of the VerticalAxisCustom property in VC++.
Code: Select all
eg. place before close of "if" clause in OnButton2()
CString text;
int i= m_Chart1.Series(1).GetVerticalAxisCustom();
text.Format(_T("Val : %d"),i);
CEdit* edTexto;
edTexto = (CEdit*) GetDlgItem(IDC_EDIT1);
edTexto->SetWindowText(text);
Regards,
Marc Meumann
Steema Support