this.plot1.Model
This discussion was imported from CodePlex
yribbens wrote at 2014-05-22 01:58:
I'm following the "Getting started" guide for Windows Forms, and also looking at the examples:
https://oxyplot.codeplex.com/SourceControl/latest#Source/Examples/DocumentationExamples/HelloWorld/WindowsFormsApplication1/Form1.cs
namespace WindowsFormsApplication1
{
Can someone explain where plot1 is created? I get an error that this definition does not exist.
Thanks!
https://oxyplot.codeplex.com/SourceControl/latest#Source/Examples/DocumentationExamples/HelloWorld/WindowsFormsApplication1/Form1.cs
namespace WindowsFormsApplication1
{
using System;
using System.Windows.Forms;
using OxyPlot;
using OxyPlot.Series;
public partial class Form1 : Form
{
public Form1()
{
this.InitializeComponent();
var myModel = new PlotModel("Example 1");
myModel.Series.Add(new FunctionSeries(Math.Cos, 0, 10, 0.1, "cos(x)"));
this.plot1.Model = myModel;
}
}
}Can someone explain where plot1 is created? I get an error that this definition does not exist.
Thanks!
objo wrote at 2014-05-23 08:17:
Thanks for the notice - the 'getting started' should be improved. The
plot1
should be a PlotView
control added to the form.Customer support service by UserEcho