Nevron Chart


Author
Message
Ram Chandran
Ram Chandran
Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)Forum Newbie (0 reputation)
Group: Forum Members
Posts: 1, Visits: 2
Hi,

When i use the following code, i am getting error in two area - NTrackballTool() "The type or namespace name NTrackballTool could not be found" and chart.Dock - "Nevron.Chart.NPieChart does not contain a definition for 'Dock' and no extension method 'Dock' accepting a first argument of type 'Nevron.Chart.NPieChart' could not be found".  Please do the needful.

using System;
using System.Windows.Forms;
using Nevron.Chart;
using Nevron.Chart.WinForm;
using Nevron.GraphicsCore;
...
private void Form1_Load(object sender, EventArgs e)
{
    nChartControl1.Controller.Tools.Add(new NSelectorTool());
    nChartControl1.Controller.Tools.Add(new NTrackballTool());
    nChartControl1.Settings.JitterMode = JitterMode.Auto;
    nChartControl1.Settings.JitteringSteps = 16;
  
    NPieChart chart = new NPieChart();
    nChartControl1.Charts.Clear();
    nChartControl1.Charts.Add(chart);
    chart.Dock = DockStyle.Fill;
    chart.DockMargins = new NMarginsL(5, 5, 5, 5);
    chart.Enable3D = true;
    chart.Width = 70;
    chart.Depth = 10;
    chart.Projection.SetPredefinedProjection(PredefinedProjection.PerspectiveElevated);
    chart.LightModel.SetPredefinedLightModel(PredefinedLightModel.ShinyCameraLight);
  
    NPieSeries pie = (NPieSeries)chart.Series.Add(SeriesType.Pie);
    pie.PieStyle = PieStyle.SmoothEdgeRing;
    pie.InnerRadius = new NLength(40);
    pie.PieEdgePercent = 15; 
    pie.LabelMode = PieLabelMode.SpiderNoOverlap;
  
    pie.AddDataPoint(new NDataPoint(12, "Cars"));
    pie.AddDataPoint(new NDataPoint(42, "Trains"));
    pie.AddDataPoint(new NDataPoint(56, "Airplanes"));
    pie.AddDataPoint(new NDataPoint(23, "Buses"));
    pie.AddDataPoint(new NDataPoint(32, "Bikes"));
    pie.AddDataPoint(new NDataPoint(29, "Boats"));
  
    NStyleSheet styleSheet = NStyleSheet.CreatePredefinedStyleSheet(PredefinedStyleSheet.BrightMultiColor);
    styleSheet.Apply(nChartControl1.Document);
  
    nChartControl1.Refresh(); 
}


GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search