Description
Obtains the line style and width for a series in a graph.
Applies to
PowerBuilder DataWindow
DataWindow control
Syntax
PowerBuilder
integer dwcontrol.GetSeriesStyle ( string graphcontrol, string seriesname, REF LineStyle linestyle {, REF integer linewidth } )
Argument |
Description |
---|---|
dwcontrol |
A reference to the DataWindow control containing the graph. |
graphcontrol |
A string whose value is the name of the graph in the DataWindow control. |
seriesname |
A string whose value is the name of the series for which you want the line style information. |
linestyle |
In PowerBuilder, a variable of type LineStyle in which you want to store the line style of seriesname. For a list of values, see LineStyle. |
linewidth (optional) |
In PowerBuilder, an integer variable in which you want to store the line width for seriesname. The width is measured in pixels. |
Return value
Returns 1 if it succeeds and -1 if an error occurs. In PowerBuilder, stores in linestyle a value of the LineStyle enumerated datatype and in linewidth the width of the line used for the specified series. If any argument's value is null, GetSeriesStyle returns null.
Examples
These statements store in the variables line_style and line_width the line style and width for the series under the mouse pointer in the graph gr_product_data:
string SeriesName integer SeriesNbr, Data_Point, line_width LineStyle line_style grObjectType MouseHit MouseHit = dw_equipment.ObjectAtPointer & ("gr_product_data", SeriesNbr, Data_Point) IF MouseHit = TypeSeries! THEN SeriesName = & dw_equipment.SeriesName("gr_product_data", & SeriesNbr) dw_equipment.GetSeriesStyle ("gr_product_data", & SeriesName, line_style, line_width) END IF
See also