diff --git a/PacticeSolution/LiveChartPractice/App.xaml b/PacticeSolution/LiveChartPractice/App.xaml
new file mode 100644
index 0000000..f5278e3
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/App.xaml
@@ -0,0 +1,9 @@
+
+
+
+
+
diff --git a/PacticeSolution/LiveChartPractice/App.xaml.cs b/PacticeSolution/LiveChartPractice/App.xaml.cs
new file mode 100644
index 0000000..22f7465
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/App.xaml.cs
@@ -0,0 +1,17 @@
+using System;
+using System.Collections.Generic;
+using System.Configuration;
+using System.Data;
+using System.Linq;
+using System.Threading.Tasks;
+using System.Windows;
+
+namespace LiveChartPractice
+{
+ ///
+ /// Interaction logic for App.xaml
+ ///
+ public partial class App : Application
+ {
+ }
+}
diff --git a/PacticeSolution/LiveChartPractice/AssemblyInfo.cs b/PacticeSolution/LiveChartPractice/AssemblyInfo.cs
new file mode 100644
index 0000000..8b5504e
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/AssemblyInfo.cs
@@ -0,0 +1,10 @@
+using System.Windows;
+
+[assembly: ThemeInfo(
+ ResourceDictionaryLocation.None, //where theme specific resource dictionaries are located
+ //(used if a resource is not found in the page,
+ // or application resource dictionaries)
+ ResourceDictionaryLocation.SourceAssembly //where the generic resource dictionary is located
+ //(used if a resource is not found in the page,
+ // app, or any theme specific resource dictionaries)
+)]
diff --git a/PacticeSolution/LiveChartPractice/LiveChartPractice.csproj b/PacticeSolution/LiveChartPractice/LiveChartPractice.csproj
new file mode 100644
index 0000000..37aed83
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/LiveChartPractice.csproj
@@ -0,0 +1,14 @@
+
+
+
+ WinExe
+ net6.0-windows
+ enable
+ true
+
+
+
+
+
+
+
diff --git a/PacticeSolution/LiveChartPractice/MainWindow.xaml b/PacticeSolution/LiveChartPractice/MainWindow.xaml
new file mode 100644
index 0000000..56f6532
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/MainWindow.xaml
@@ -0,0 +1,42 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/PacticeSolution/LiveChartPractice/MainWindow.xaml.cs b/PacticeSolution/LiveChartPractice/MainWindow.xaml.cs
new file mode 100644
index 0000000..ac66c1f
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/MainWindow.xaml.cs
@@ -0,0 +1,48 @@
+using LiveCharts.Wpf;
+using LiveCharts;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Navigation;
+using System.Windows.Shapes;
+
+namespace LiveChartPractice
+{
+ ///
+ /// Interaction logic for MainWindow.xaml
+ ///
+ public partial class MainWindow : Window
+ {
+ public MainWindow()
+ {
+ InitializeComponent();
+ }
+
+ private void btnSeriesAdd_Click(object sender, RoutedEventArgs e)
+ {
+ SampleData data = this.DataContext as SampleData;
+ if (data == null)
+ return;
+
+ Random rand = new Random();
+ data.SeriesCollection.Add(new LineSeries
+ {
+ Title = $"Series {data.SeriesCollection.Count + 1}",
+ Values = new ChartValues { rand.Next(1, 8), rand.Next(1, 8), rand.Next(1, 8), rand.Next(1, 8), rand.Next(1, 8) },
+ LineSmoothness = rand.Next(0, 2), //0: straight lines, 1: really smooth lines
+ //PointGeometry = Geometry.Parse("m 25 70.36218 20 -28 -20 22 -8 -6 z"),
+ //PointGeometrySize = 50,
+ //PointForeground = Brushes.Gray
+ });
+ }
+ }
+}
diff --git a/PacticeSolution/LiveChartPractice/SampleData.cs b/PacticeSolution/LiveChartPractice/SampleData.cs
new file mode 100644
index 0000000..8bd1957
--- /dev/null
+++ b/PacticeSolution/LiveChartPractice/SampleData.cs
@@ -0,0 +1,45 @@
+using LiveCharts;
+using LiveCharts.Wpf;
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace LiveChartPractice
+{
+ public class SampleData
+ {
+ public SeriesCollection SeriesCollection { get; set; }
+ public string[] Labels { get; set; }
+ public Func YFormatter { get; set; }
+
+ public SampleData()
+ {
+ this.SeriesCollection = new SeriesCollection()
+ {
+ new LineSeries()
+ {
+ Title = "Series 1",
+ Values = new ChartValues { 4, 6, 5, 2, 4 }
+ },
+ new LineSeries()
+ {
+ Title = "Series 2",
+ Values = new ChartValues { 6, 7, 3, 4 ,6 },
+ PointGeometry = null
+ },
+ new LineSeries()
+ {
+ Title = "Series 3",
+ Values = new ChartValues { 4, 2, 7, 2, 7 },
+ PointGeometry = DefaultGeometries.Square,
+ PointGeometrySize = 15
+ },
+ };
+
+ this.Labels = new[] { "Jan", "Feb", "Mar", "Apr", "May" };
+ this.YFormatter = value => value.ToString("C");
+ }
+ }
+}
diff --git a/PacticeSolution/PacticeSolution.sln b/PacticeSolution/PacticeSolution.sln
index 344a4cf..2251b20 100644
--- a/PacticeSolution/PacticeSolution.sln
+++ b/PacticeSolution/PacticeSolution.sln
@@ -133,9 +133,11 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TimerAndWorker", "TimerAndW
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TreeViewSample", "TreeViewSample\TreeViewSample.csproj", "{CA88EE83-8C7F-4FEF-963A-DEACA5E502FB}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "TriggerAnimations", "TriggerAnimations\TriggerAnimations.csproj", "{9D9FD436-C73C-4DB4-A311-09D2DB65E03E}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "TriggerAnimations", "TriggerAnimations\TriggerAnimations.csproj", "{9D9FD436-C73C-4DB4-A311-09D2DB65E03E}"
EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ChartSample", "ChartSample\ChartSample.csproj", "{2052E6D4-43B5-4847-B629-B844E521C807}"
+Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ChartSample", "ChartSample\ChartSample.csproj", "{2052E6D4-43B5-4847-B629-B844E521C807}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LiveChartPractice", "LiveChartPractice\LiveChartPractice.csproj", "{4B945CF3-2E74-46AA-8EFC-21B6434A4AC2}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -411,6 +413,10 @@ Global
{2052E6D4-43B5-4847-B629-B844E521C807}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2052E6D4-43B5-4847-B629-B844E521C807}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2052E6D4-43B5-4847-B629-B844E521C807}.Release|Any CPU.Build.0 = Release|Any CPU
+ {4B945CF3-2E74-46AA-8EFC-21B6434A4AC2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {4B945CF3-2E74-46AA-8EFC-21B6434A4AC2}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {4B945CF3-2E74-46AA-8EFC-21B6434A4AC2}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {4B945CF3-2E74-46AA-8EFC-21B6434A4AC2}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE