DrawGraph

RetVal=DrawGraph(ID, Type, Labels, XSize, YSize, YMaxType, YMaxValue, YMinType, YMinValue, SecondsBack, XScale, Filename, GraphName, BorderColor, TargetIDs, TargetName, TargetColor, NumTargets)

Description Draws a graph and saves it to a file. It can also draw a state history diagram for an alarm.
Arguments
[in] IDEither the GraphID, in the case of a normal graph, or in the case of an alarm target, the TargetID.
[in] TypeType can be one of 4 values

  • 0-Active Recording Graph
  • 1-5 Minute Recording Graph
  • 2-30 Minutes Recording Graph
  • 3-3 Hours Recording Graph
  • 4-18 Hours Recording Graph
  • 255-Alarm Recording Graph
[in] LabelsThe type of labels drawn on the graph axis

  • 0-No Axes
  • 1-Graph Indicator
  • 2-Full Axis labels
  • 3-Full Axis labels and gridlines.
[in] XSizeThe number of pixels wide the output graph will be.
[in] YSizeThe number of pixels high the output Graph will be.
[in] YMaxTypeHow the YMax Value is determined. There are three options:
  • Default- The YMax Value is taken from the settings of Net-Probe
  • Auto- The YMax Value is set to the Maximum value during the time period shown
  • Manual- The YMaxValue will be used to set the YMax of the graph
[in] YMaxValueThe Maximum value Y value on the graph.
[in] YMinTypeHow the YMin Value is determined. The are three options:

  • Default- The YMin Value is taken from the settings of Net-Probe
  • Auto- The YMin Value is set to the Minimum value during the time period shown
  • Manual- The YMinValue will be used to set the YMin of the graph
[in] YMinValueThe Mimimum value Y value on the graph.
[in] SecondsBackThe X axis of all Net-Probe graphs indicates seconds back from now (with seconds back set to zero). Increasing this value skips the number of seconds specified.
[in] XScaleWith a value of 1, one pixel on the screen represents one recorded value. This floating value can be used to get more or less detail within a time period.
[in,out] FilenameIs specified, then the resulting graph is placed in this file. If not then the file name will be constructed from the values set with SetTmpImagePath method.
[out] GraphNameThe title of the graph.
[out] BorderColorThe border color of the graph
[out] TargetIDsAn array of integers, starting from 1, defining the TargetIDs found on the graph.
[out] TargetNameAn array of strings, starting from 1, providing the names of the targets on the graph.
[out] TargetColorAn array of integers, starting from 1, providing the colors of each target on the graph.
[out] NumTargetsThe number of targets shown on the graph.
Return Value Zero indicates success, One indicates failure to communicate with service and Two a failure in obtaining the graph.

Copyright (c) Warren Flemmer 2006www.net-probe.com