Solution
The
AfterDrawPlot event is used to draw the grid lines on an intensity graph, you can use this event in conjunction with custom drawing to further annotate the plot. Only plots contained in the graph plot collection raise
AfterDrawPlot after the plot has completed drawing.
Include the following lines in your code to draw the grid lines in your graph:
private void intensityGraph1_AfterDrawPlot(object sender, NationalInstruments.UI.AfterDrawIntensityPlotEventArgs e)
{
intensityGraph1.DrawGridLines(new NationalInstruments.UI.ComponentDrawArgs(e.Graphics, e.Bounds));
}
Note: intensityGraph1 is the object name for this specific code example, make sure to include the proper name of the intensity graph used on the program.