From fd257ce432f67c208ae14471f1fcdecaede1764d Mon Sep 17 00:00:00 2001 From: Kamalesh-Periyasamy Date: Fri, 27 Mar 2026 13:02:26 +0530 Subject: [PATCH 1/2] removed old sample --- GettingStarted_Chart/GettingStarted_Chart.sln | 31 ----- .../GettingStarted_Chart/App.config | 6 - .../GettingStarted_Chart/Form1.Designer.cs | 111 ---------------- .../GettingStarted_Chart/Form1.cs | 20 --- .../GettingStarted_Chart/Form1.resx | 120 ------------------ .../GettingStarted_Chart.csproj | 108 ---------------- .../GettingStarted_Chart/Program.cs | 22 ---- .../Properties/AssemblyInfo.cs | 36 ------ .../Properties/Resources.Designer.cs | 71 ----------- .../Properties/Resources.resx | 117 ----------------- .../Properties/Settings.Designer.cs | 30 ----- .../Properties/Settings.settings | 7 - .../GettingStarted_Chart/SalesData.cs | 35 ----- .../GettingStarted_Chart/packages.config | 8 -- 14 files changed, 722 deletions(-) delete mode 100644 GettingStarted_Chart/GettingStarted_Chart.sln delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/App.config delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Form1.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Form1.resx delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Program.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Properties/AssemblyInfo.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.Designer.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.resx delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.Designer.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.settings delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/SalesData.cs delete mode 100644 GettingStarted_Chart/GettingStarted_Chart/packages.config diff --git a/GettingStarted_Chart/GettingStarted_Chart.sln b/GettingStarted_Chart/GettingStarted_Chart.sln deleted file mode 100644 index bf90239..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart.sln +++ /dev/null @@ -1,31 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 16 -VisualStudioVersion = 16.0.29911.84 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "GettingStarted_Chart", "GettingStarted_Chart\GettingStarted_Chart.csproj", "{3FCCF646-1E13-4BD1-9919-0BDA35A468CE}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Debug-Xml|Any CPU = Debug-Xml|Any CPU - Release|Any CPU = Release|Any CPU - Release-Xml|Any CPU = Release-Xml|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Debug|Any CPU.Build.0 = Debug|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Debug-Xml|Any CPU.ActiveCfg = Debug|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Debug-Xml|Any CPU.Build.0 = Debug|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Release|Any CPU.ActiveCfg = Release|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Release|Any CPU.Build.0 = Release|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Release-Xml|Any CPU.ActiveCfg = Release|Any CPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE}.Release-Xml|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {8FBDE750-8622-477B-AE16-7EA0B14CB742} - EndGlobalSection -EndGlobal diff --git a/GettingStarted_Chart/GettingStarted_Chart/App.config b/GettingStarted_Chart/GettingStarted_Chart/App.config deleted file mode 100644 index 8324aa6..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/App.config +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs b/GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs deleted file mode 100644 index 70b196c..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs +++ /dev/null @@ -1,111 +0,0 @@ -using Syncfusion.Drawing; -using Syncfusion.Windows.Forms.Chart; -using System.ComponentModel; -using System.Drawing; -using System.Windows.Forms; - -namespace GettingStarted_Chart -{ - partial class Form1 - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - Panel panel = new Panel(); - - this.chartControl1 = new Syncfusion.Windows.Forms.Chart.ChartControl(); - this.SuspendLayout(); - panel.SuspendLayout(); - // - // chartControl1 - // - this.chartControl1.ChartArea.BackInterior = new Syncfusion.Drawing.BrushInfo(System.Drawing.Color.Transparent); - this.chartControl1.ChartArea.CursorLocation = new System.Drawing.Point(0, 0); - this.chartControl1.ChartArea.CursorReDraw = false; - this.chartControl1.DataSourceName = "[none]"; - this.chartControl1.IsWindowLess = false; - this.chartControl1.TabIndex = 0; - this.chartControl1.Skins = Skins.Metro; - - // - // PrimaryXAxis - // - this.chartControl1.PrimaryXAxis.ValueType = ChartValueType.Category; - this.chartControl1.PrimaryXAxis.TitleColor = System.Drawing.SystemColors.ControlText; - - BindingList dataSource = new BindingList(); - dataSource.Add(new SalesData("1999", 3)); - dataSource.Add(new SalesData("2000", 7)); - dataSource.Add(new SalesData("2001", 12)); - dataSource.Add(new SalesData("2002", 18)); - dataSource.Add(new SalesData("2003", 22)); - dataSource.Add(new SalesData("2004", 30)); - dataSource.Add(new SalesData("2005", 40)); - dataSource.Add(new SalesData("2006", 50)); - dataSource.Add(new SalesData("2007", 65)); - dataSource.Add(new SalesData("2008", 75)); - - CategoryAxisDataBindModel dataSeriesModel = new CategoryAxisDataBindModel(dataSource); - dataSeriesModel.CategoryName = "Year"; - dataSeriesModel.YNames = new string[] { "Sales" }; - - ChartSeries chartSeries = new ChartSeries("Sales"); - chartSeries.CategoryModel = dataSeriesModel; - chartSeries.Style.DisplayText = true; - chartSeries.Style.TextOrientation = ChartTextOrientation.Up; - - this.chartControl1.Legend.Visible = true; - this.chartControl1.LegendAlignment = ChartAlignment.Center; - this.chartControl1.Legend.Position = ChartDock.Top; - this.chartControl1.LegendsPlacement = ChartPlacement.Outside; - this.chartControl1.Series.Add(chartSeries); - - this.chartControl1.ShowToolTips = true; - this.chartControl1.Tooltip.BackgroundColor = new BrushInfo(Color.White); - this.chartControl1.Tooltip.BorderStyle = BorderStyle.FixedSingle; - this.chartControl1.Tooltip.Font = new Font("Segoe UI", 10); - chartSeries.PointsToolTipFormat = "{2}"; - - this.chartControl1.Size = new System.Drawing.Size(1500, 450); - this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F); - this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(821, 577); - - panel.AutoSize = true; - panel.Controls.Add(chartControl1); - - this.Controls.Add(panel); - this.Name = "Form1"; - this.Text = "Form1"; - this.ResumeLayout(false); - } - - #endregion - - private Syncfusion.Windows.Forms.Chart.ChartControl chartControl1; - } -} - diff --git a/GettingStarted_Chart/GettingStarted_Chart/Form1.cs b/GettingStarted_Chart/GettingStarted_Chart/Form1.cs deleted file mode 100644 index 610d119..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Form1.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace GettingStarted_Chart -{ - public partial class Form1 : Form - { - public Form1() - { - InitializeComponent(); - } - } -} diff --git a/GettingStarted_Chart/GettingStarted_Chart/Form1.resx b/GettingStarted_Chart/GettingStarted_Chart/Form1.resx deleted file mode 100644 index 1af7de1..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Form1.resx +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj b/GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj deleted file mode 100644 index 2375f69..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj +++ /dev/null @@ -1,108 +0,0 @@ - - - - - Debug - AnyCPU - {3FCCF646-1E13-4BD1-9919-0BDA35A468CE} - WinExe - Properties - WindowsFormsApplication1 - WindowsFormsApplication1 - v4.6 - 512 - true - - - AnyCPU - true - full - false - bin\Debug\ - DEBUG;TRACE - prompt - 4 - - - AnyCPU - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - ..\packages\Syncfusion.Chart.Base.18.2.0.58\lib\net46\Syncfusion.Chart.Base.dll - - - ..\packages\Syncfusion.Chart.Windows.18.2.0.58\lib\net46\Syncfusion.Chart.Windows.dll - - - ..\packages\Syncfusion.Grouping.Base.18.2.0.58\lib\net46\Syncfusion.Grouping.Base.dll - - - ..\packages\Syncfusion.Licensing.18.2.0.58\lib\net46\Syncfusion.Licensing.dll - - - ..\packages\Syncfusion.Shared.Base.18.2.0.58\lib\net46\Syncfusion.Shared.Base.dll - - - - - - - - - - - - - - - - - Form - - - Form1.cs - - - - - - Form1.cs - - - ResXFileCodeGenerator - Resources.Designer.cs - Designer - - - True - Resources.resx - - - - SettingsSingleFileGenerator - Settings.Designer.cs - - - True - Settings.settings - True - - - - - - - - \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/Program.cs b/GettingStarted_Chart/GettingStarted_Chart/Program.cs deleted file mode 100644 index f7ebdf2..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Program.cs +++ /dev/null @@ -1,22 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Threading.Tasks; -using System.Windows.Forms; - -namespace GettingStarted_Chart -{ - static class Program - { - /// - /// The main entry point for the application. - /// - [STAThread] - static void Main() - { - Application.EnableVisualStyles(); - Application.SetCompatibleTextRenderingDefault(false); - Application.Run(new Form1()); - } - } -} diff --git a/GettingStarted_Chart/GettingStarted_Chart/Properties/AssemblyInfo.cs b/GettingStarted_Chart/GettingStarted_Chart/Properties/AssemblyInfo.cs deleted file mode 100644 index 8efd043..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,36 +0,0 @@ -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyTitle("WindowsFormsApplication1")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("WindowsFormsApplication1")] -[assembly: AssemblyCopyright("Copyright © 2018")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from -// COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] - -// The following GUID is for the ID of the typelib if this project is exposed to COM -[assembly: Guid("3fccf646-1e13-4bd1-9919-0bda35a468ce")] - -// Version information for an assembly consists of the following four values: -// -// Major Version -// Minor Version -// Build Number -// Revision -// -// You can specify all the values or you can default the Build and Revision Numbers -// by using the '*' as shown below: -// [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.Designer.cs b/GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.Designer.cs deleted file mode 100644 index ad0ace6..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.Designer.cs +++ /dev/null @@ -1,71 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:4.0.30319.42000 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace GettingStarted_Chart.Properties -{ - - - /// - /// A strongly-typed resource class, for looking up localized strings, etc. - /// - // This class was auto-generated by the StronglyTypedResourceBuilder - // class via a tool like ResGen or Visual Studio. - // To add or remove a member, edit your .ResX file then rerun ResGen - // with the /str option, or rebuild your VS project. - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")] - [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - internal class Resources - { - - private static global::System.Resources.ResourceManager resourceMan; - - private static global::System.Globalization.CultureInfo resourceCulture; - - [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")] - internal Resources() - { - } - - /// - /// Returns the cached ResourceManager instance used by this class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Resources.ResourceManager ResourceManager - { - get - { - if ((resourceMan == null)) - { - global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("WindowsFormsApplication1.Properties.Resources", typeof(Resources).Assembly); - resourceMan = temp; - } - return resourceMan; - } - } - - /// - /// Overrides the current thread's CurrentUICulture property for all - /// resource lookups using this strongly typed resource class. - /// - [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)] - internal static global::System.Globalization.CultureInfo Culture - { - get - { - return resourceCulture; - } - set - { - resourceCulture = value; - } - } - } -} diff --git a/GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.resx b/GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.resx deleted file mode 100644 index af7dbeb..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Properties/Resources.resx +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.Designer.cs b/GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.Designer.cs deleted file mode 100644 index c71270d..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.Designer.cs +++ /dev/null @@ -1,30 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// Runtime Version:4.0.30319.42000 -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace GettingStarted_Chart.Properties -{ - - - [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] - [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")] - internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase - { - - private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); - - public static Settings Default - { - get - { - return defaultInstance; - } - } - } -} diff --git a/GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.settings b/GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.settings deleted file mode 100644 index 3964565..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/Properties/Settings.settings +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/GettingStarted_Chart/GettingStarted_Chart/SalesData.cs b/GettingStarted_Chart/GettingStarted_Chart/SalesData.cs deleted file mode 100644 index 645e614..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/SalesData.cs +++ /dev/null @@ -1,35 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Threading.Tasks; - -namespace GettingStarted_Chart -{ - public class SalesData - { - private string year; - - private double sales; - - public string Year - { - get { return year; } - - set { year = value; } - } - public double Sales - { - get { return sales; } - - set { sales = value; } - } - - public SalesData(string year, double sales) - { - this.year = year; - - this.sales = sales; - } - } -} \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/packages.config b/GettingStarted_Chart/GettingStarted_Chart/packages.config deleted file mode 100644 index 966f789..0000000 --- a/GettingStarted_Chart/GettingStarted_Chart/packages.config +++ /dev/null @@ -1,8 +0,0 @@ - - - - - - - - \ No newline at end of file From 1e326f50dd947eb24390e68128d4a900e68cf90d Mon Sep 17 00:00:00 2001 From: Kamalesh-Periyasamy Date: Fri, 27 Mar 2026 13:03:08 +0530 Subject: [PATCH 2/2] added new sample --- .../GettingStarted_Chart.slnx | 3 + .../GettingStarted_Chart/Form1.Designer.cs | 112 ++++++++++++++++ .../GettingStarted_Chart/Form1.cs | 10 ++ .../GettingStarted_Chart/Form1.resx | 120 ++++++++++++++++++ .../GettingStarted_Chart.csproj | 15 +++ .../GettingStarted_Chart/Program.cs | 17 +++ .../GettingStarted_Chart/SalesData.cs | 35 +++++ 7 files changed, 312 insertions(+) create mode 100644 GettingStarted_Chart/GettingStarted_Chart.slnx create mode 100644 GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs create mode 100644 GettingStarted_Chart/GettingStarted_Chart/Form1.cs create mode 100644 GettingStarted_Chart/GettingStarted_Chart/Form1.resx create mode 100644 GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj create mode 100644 GettingStarted_Chart/GettingStarted_Chart/Program.cs create mode 100644 GettingStarted_Chart/GettingStarted_Chart/SalesData.cs diff --git a/GettingStarted_Chart/GettingStarted_Chart.slnx b/GettingStarted_Chart/GettingStarted_Chart.slnx new file mode 100644 index 0000000..f14eb0d --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart.slnx @@ -0,0 +1,3 @@ + + + diff --git a/GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs b/GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs new file mode 100644 index 0000000..f26d27e --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart/Form1.Designer.cs @@ -0,0 +1,112 @@ +using Syncfusion.Drawing; +using Syncfusion.Windows.Forms.Chart; +using System.ComponentModel; +using System.Drawing; +using System.Windows.Forms; +using static System.Windows.Forms.VisualStyles.VisualStyleElement; + +namespace GettingStarted_Chart +{ + partial class Form1 + { + /// + /// Required designer variable. + /// + private System.ComponentModel.IContainer components = null; + + /// + /// Clean up any resources being used. + /// + /// true if managed resources should be disposed; otherwise, false. + protected override void Dispose(bool disposing) + { + if (disposing && (components != null)) + { + components.Dispose(); + } + base.Dispose(disposing); + } + + #region Windows Form Designer generated code + + /// + /// Required method for Designer support - do not modify + /// the contents of this method with the code editor. + /// + private void InitializeComponent() + { + Panel panel = new Panel(); + + this.chartControl1 = new Syncfusion.Windows.Forms.Chart.ChartControl(); + this.SuspendLayout(); + panel.SuspendLayout(); + // + // chartControl1 + // + this.chartControl1.ChartArea.BackInterior = new Syncfusion.Drawing.BrushInfo(System.Drawing.Color.Transparent); + this.chartControl1.ChartArea.CursorLocation = new System.Drawing.Point(0, 0); + this.chartControl1.ChartArea.CursorReDraw = false; + this.chartControl1.DataSourceName = "[none]"; + this.chartControl1.IsWindowLess = false; + this.chartControl1.TabIndex = 0; + this.chartControl1.Skins = Skins.Metro; + + // + // PrimaryXAxis + // + this.chartControl1.PrimaryXAxis.ValueType = ChartValueType.Category; + this.chartControl1.PrimaryXAxis.TitleColor = System.Drawing.SystemColors.ControlText; + + BindingList dataSource = new BindingList(); + dataSource.Add(new SalesData("1999", 3)); + dataSource.Add(new SalesData("2000", 7)); + dataSource.Add(new SalesData("2001", 12)); + dataSource.Add(new SalesData("2002", 18)); + dataSource.Add(new SalesData("2003", 22)); + dataSource.Add(new SalesData("2004", 30)); + dataSource.Add(new SalesData("2005", 40)); + dataSource.Add(new SalesData("2006", 50)); + dataSource.Add(new SalesData("2007", 65)); + dataSource.Add(new SalesData("2008", 75)); + + CategoryAxisDataBindModel dataSeriesModel = new CategoryAxisDataBindModel(dataSource); + dataSeriesModel.CategoryName = "Year"; + dataSeriesModel.YNames = new string[] { "Sales" }; + + ChartSeries chartSeries = new ChartSeries("Sales"); + chartSeries.CategoryModel = dataSeriesModel; + chartSeries.Style.DisplayText = true; + chartSeries.Style.TextOrientation = ChartTextOrientation.Up; + + this.chartControl1.Legend.Visible = true; + this.chartControl1.LegendAlignment = ChartAlignment.Center; + this.chartControl1.Legend.Position = ChartDock.Top; + this.chartControl1.LegendsPlacement = ChartPlacement.Outside; + this.chartControl1.Series.Add(chartSeries); + + this.chartControl1.ShowToolTips = true; + this.chartControl1.Tooltip.BackgroundColor = new BrushInfo(Color.White); + this.chartControl1.Tooltip.BorderStyle = BorderStyle.FixedSingle; + this.chartControl1.Tooltip.Font = new Font("Segoe UI", 10); + chartSeries.PointsToolTipFormat = "{2}"; + + this.chartControl1.Size = new System.Drawing.Size(1500, 450); + this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 20F); + this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; + this.ClientSize = new System.Drawing.Size(821, 577); + + panel.AutoSize = true; + panel.Controls.Add(chartControl1); + + this.Controls.Add(panel); + this.Name = "Form1"; + this.Text = "Form1"; + this.ResumeLayout(false); + } + + #endregion + + private Syncfusion.Windows.Forms.Chart.ChartControl chartControl1; + } +} + diff --git a/GettingStarted_Chart/GettingStarted_Chart/Form1.cs b/GettingStarted_Chart/GettingStarted_Chart/Form1.cs new file mode 100644 index 0000000..82f57fc --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart/Form1.cs @@ -0,0 +1,10 @@ +namespace GettingStarted_Chart +{ + public partial class Form1 : Form + { + public Form1() + { + InitializeComponent(); + } + } +} diff --git a/GettingStarted_Chart/GettingStarted_Chart/Form1.resx b/GettingStarted_Chart/GettingStarted_Chart/Form1.resx new file mode 100644 index 0000000..1af7de1 --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart/Form1.resx @@ -0,0 +1,120 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + text/microsoft-resx + + + 2.0 + + + System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + + System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 + + \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj b/GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj new file mode 100644 index 0000000..54f56f4 --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart/GettingStarted_Chart.csproj @@ -0,0 +1,15 @@ + + + + WinExe + net10.0-windows + enable + true + enable + + + + + + + \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/Program.cs b/GettingStarted_Chart/GettingStarted_Chart/Program.cs new file mode 100644 index 0000000..867f25c --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart/Program.cs @@ -0,0 +1,17 @@ +namespace GettingStarted_Chart +{ + internal static class Program + { + /// + /// The main entry point for the application. + /// + [STAThread] + static void Main() + { + // To customize application configuration such as set high DPI settings or default font, + // see https://aka.ms/applicationconfiguration. + ApplicationConfiguration.Initialize(); + Application.Run(new Form1()); + } + } +} \ No newline at end of file diff --git a/GettingStarted_Chart/GettingStarted_Chart/SalesData.cs b/GettingStarted_Chart/GettingStarted_Chart/SalesData.cs new file mode 100644 index 0000000..645e614 --- /dev/null +++ b/GettingStarted_Chart/GettingStarted_Chart/SalesData.cs @@ -0,0 +1,35 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace GettingStarted_Chart +{ + public class SalesData + { + private string year; + + private double sales; + + public string Year + { + get { return year; } + + set { year = value; } + } + public double Sales + { + get { return sales; } + + set { sales = value; } + } + + public SalesData(string year, double sales) + { + this.year = year; + + this.sales = sales; + } + } +} \ No newline at end of file