RMC_AddLineSeries function.
Add a line chart series to a region of an existing chart

Syntax
nResult& = RMC_AddLineSeries(
ByVal nCtrlId (LONG),
ByVal nRegion (LONG),
Optional ByRef nFirstDataValue (DOUBLE),
Optional ByVal nDataValuesCount (LONG),
Optional ByRef nFirstPPCValue (LONG),
Optional ByVal nPPCValuesCount (LONG),
Optional ByVal nType (LONG),
Optional ByVal nStyle (LONG),
Optional ByVal nLineStyle (LONG),
Optional ByVal nIsLucent (LONG),
Optional ByVal nColor (LONG),
Optional ByVal nSymbol (LONG),
Optional ByVal nWhichDataAxis (LONG),
Optional ByVal nValueLabelOn (LONG),
Optional ByVal nHatchMode (LONG)
)

See Remarks
Parameter
nCtrlId (LONG)
Unique ID of the chart control, to which the series belongs.
nRegion (LONG)
Region to which the series belongs.
nFirstDataValue (DOUBLE)
The first element of an one-dimensional array, which holds the series data. If you want to add the data later with RMC_SetSeriesData(), simply pass 0.
nDataValuesCount (LONG)
The total number of elements in the data array or zero, if you want to add the data later.
nFirstPPCValue (LONG)
First element of an one-dimensional array with the amount of data points for each column. See Remarks
nPPCValuesCount (LONG)
The total number of elements in the PointsPerColumn-array.
nType (LONG)
Type of the series as a chart type constant. If omitted or 0: RMC_LINE.
nStyle (LONG)
Style of the series as a chart style constant. If omitted or 0: If type = RMC_LINE or RMC_LINE_INDEXED: RMC_LINE_FLAT. If type = RMC_AREA or RMC_AREA_INDEXED: RMC_AREA_FLAT
nLineStyle (LONG)
Style of the line or area as a line style constant. If omitted or 0: RMC_LSTYLE_LINE
nIsLucent (LONG)
If TRUE, the transparency is switched on, if FALSE not. If omitted or 0: FALSE. Transperancy is reasonable only for type RMC_AREA, with RMC_LINE transparency has no special effect.
nColor (LONG)
Color of the lines as a Color...constant. If omitted or 0: One of the internal color values, which corresponds to the series index, where the first added series has the index 1, the second the index 2 and so on.
nSymbol (LONG)
Symbol for each data point, defined as a symobl constant. If omitted or 0: no symbol will be used.
nWhichDataAxis (LONG)
Decides, to which data axis the series is connected. 1 for the first, 2 for the second axis (if existent). First and second means the order, in which the axis via RMC_AddDataAxis() was added to the region. If omitted or 0: 1
nValueLabelOn (LONG)
If TRUE, labels with the value of each data point are painted. If omitted or 0: FALSE
nHatchMode (LONG)
Normally solid colors are used to fill the aerea series. It might be usefull (specially when printing) to fill the areas with a hatch brush instead of a solid brush. In this case use this parameter. There are three possible values:
  • RMC_HATCHBRUSH_OFF: Only solid brushes are used to fill the objects. This is the default.
  • RMC_HATCHBRUSH_ON: Hatch brushes instead of solid brushes are used to fill the objects. Ten different hatch brushes are defined in an internal array. Series 1 gets the first brush, series 2 the second and so on.
  • RMC_HATCHBRUSH_ONPRINTING: If showing the chart on the screen (or exporting it to a bitmap), solid brushes are used. If sending the chart to the printer, hatch brushes are used.
This parameter only affects the series types RMC_AREA and RMC_AREA_INDEXED, lines are always painted in solid colors.
Hatch brushes should only be used with the non-gradient styles. It's nearly impossible to find a good balance between the gradient effect and the hatch brushes, and if it might be ok for the screen, it's not ok for the printer. Also use hatch brushes only with the more lighter colors, not with the dark ones.
Return value
0
No error, function succeeded.
RMC_ERROR_CTRLID
Wrong control ID (0 or no chart with this control ID was found).
RMC_ERROR_MAXREGION
The region index exceeds the maximum possible numbers of regions (6) within a chart control.
RMC_ERROR_WRONGREGION
The region index is inexistent in the chart control.
RMC_ERROR_MAXSERIES
The actual series exceeds the maximum possible numbers of series (15) within a region.
RMC_ERROR_ALLOC
Error while allocating memory for the data.
Remarks
The PointsPerColumn-array must either be empty ( = undimensioned) or the size of the array must match the amount of label axis columns as defined in RMC_AddLabelAxis(). If the array is empty (or you pass simply a 0),the data points will be evenly spread across the grid. If you have e.g. ten data points in the data-array and the label axis was defined with ten columns, each column will hold one data point. Did you instead only define 5 columns for the label axis, each column will hold 2 data points. If you need a higher grade of accuracy (e.g. in financial charts), each element of the PointsPerColumn-array should hold the number of data points, which will be painted in each column.