Page 1 of 1

Re: Dynamic or run-time edit

Posted: Wed Nov 15, 2006 6:05 am
by 9043243
Hi experts,

We bought TeeChart standard V7 and installed in Delphi2006 professional (with update2) for existing porject which I took over recently. I am new to TeeChart and Delphi, now I have a quesiotn

(1) We know when creating a new chart with TChar,if you want edit new chart, you only need "Position the mousepointer over the new Chart and press the right mousebutton. A menu appears that includes the ‘Edit Chart’ option"., my question is can I do that on the run-time ? That is when the application program is displaying a graph and you press right mouse then this 'Edit Chart' will come up to allow you use print veiw, export data...etc. If yes, please tell me how ? Thanks in advance.

Daniel

Posted: Wed Nov 15, 2006 8:11 am
by Marjan
Hi.

Yes, you can invoke chart editor at runtime. There are several ways to do it.
1) Drop a TChartEditor on the form, connect it to specific chart by setting it's Chart property and finally invoke chart editor at runtime by:

Code: Select all

ChartEditor1.Execute;
This method offers more customization: it allows you to specify which chart editor page(s) and options will be enabled. In case you want to bring up editor will all options enabled, you can also use the following method:

2) Add the EditChar unit to the form Uses section and then invoke chart editor with the following

Code: Select all

Uses ..., EditChar;
...
  EditChart(Form1,Chart1);