Page 1 of 1

Border Editor Issue

Posted: Tue Jul 03, 2018 2:57 pm
by 16683749
Hi,
We are currently facing an issue for the Color Line tool when opening the border editor dialog through code. Earlier we were using TeeChart Pro ActiveX 2007, where the editor appeared through the following code:
m_Chart1.GetTools().GetItems(pItem->iRow-1).GetAsColorLine().GetPen().ShowEditor();

Now we have upgraded to TeeChart Pro ActiveX 2018 and now while opening the border editor dialog, few parameters are also expected as shown below:
m_Chart1.GetTools().GetItems(pItem->iRow - 1).GetAsColorLine().GetPen().ShowEditor(FALSE , "Annotation Editor" , 1);
We have specified the first two parameters but are not sure about the third parameter. Currently we are passing 1 for the third parameter(i.e. ownerChart) but this code gives access violation. The image has given below:
Please suggest as to how to open the border editor dialog.

Regards,
Bhanu
2018-07-03_072212.png
2018-07-03_072212.png (15.59 KiB) Viewed 11650 times

Re: Border Editor Issue

Posted: Thu Jul 05, 2018 8:36 am
by yeray
Hello,

I haven't tried in Visual C++ but in VB6 both "-1" and "TChart1.ChartLink" work for me here as third parameter:

Code: Select all

TChart1.Tools.Items(0).asColorLine.Pen.ShowEditor False, "Border Editor", -1

Code: Select all

TChart1.Tools.Items(0).asColorLine.Pen.ShowEditor False, "Border Editor", TChart1.ChartLink