I'm trying to make a report that prints a chart in a format other than the default. I'd like to (1) cause the chart to be a line graph instead of a bar chart, (2) drop the legend, and (3) show the values on the X-Axis.
The following BeforeOpenTables method of my report charts the data from a cursor called cCount, but it takes all of the MS Chart defaults. It displays cCount.counts on the Y-axis, but provides a differently colored bar for each corresponding value of cCount.postmark. There is a legend on the right side of the chart showing which color corresponds to which X value. The X values are not displayed on the X-axis.
The following BeforeOpenTables method of my report charts the data from a cursor called cCount, but it takes all of the MS Chart defaults. It displays cCount.counts on the Y-axis, but provides a differently colored bar for each corresponding value of cCount.postmark. There is a legend on the right side of the chart showing which color corresponds to which X value. The X values are not displayed on the X-axis.
Code:
SELECT cCount
*!* Load the chart.
#DEFINE CRLF CHR(13) + CHR(10)
#DEFINE TAB CHR(9)
LOCAL My_Data
My_Data = "" + CRLF
SCAN
My_Data = My_Data + DTOC(cCount.postmark)
My_Data = My_Data + TAB
My_Data = My_Data + LTRIM(STR(cCount.counts)) + CRLF
ENDSCAN
SELECT graphs
APPEND GENERAL olegraph CLASS "msgraph.chart" DATA My_Data