DJV Guest
|
Posted: Mon Jun 27, 2005 4:28 pm Post subject: VTCHART control under C++ Builder and Entering Data Programm |
|
|
It appears that Borland Builder6.0 comes with VtChart, which looks very much like the ActiveX control that comes with VB 5.0. I am seeking to learn how to programatically assign data to the chart elements. It appears that this control will also permit certain elements to be rendered not visible, which may enable me to eliminate the problem with unequal series of points being plotted. Unfortunately, it appears that the "Data" property is no longer defined to be a number under Borland Builder.
| Quote: | When I type in the following:
VtChart1->ChartType = VtChChartType3dBar;
VtChart1->ColumnCount = 8;
VtChart1->RowCount = 8;
int column, row;
for(column=0; column<8; column++)
{
for (row = 0; row<8; row++)
VtChart1->Column = column;
VtChart1->Row = row;
VtChart1->Data = row * 10 }
}
I get a problem with "VtChart1->Data = row * 10" due to the Data property being a string under Builder, while the example in the instruction book on the CD claims that the code in the original example (apparently written for Visual Basic) is written in such a manner so as to cause "Data" to be able to be set equal to the value of "row * 10".
How do you set data points programmatically with this control?Any way to get this straightened out? My goal is to be able to plot a series of six points then plot a series of, say, a hundred points, and be able to show both on the same X-Y plot, without introducing 94 meaningless points on the six point plot.
|
|
|