Syncfusion geupdated
Refactoring durchgeführt
This commit is contained in:
@@ -31,6 +31,7 @@ namespace BerichtGen
|
|||||||
/// <param name="erzeugePDF">Ein Pdf datei soll erzeugt werden</param>
|
/// <param name="erzeugePDF">Ein Pdf datei soll erzeugt werden</param>
|
||||||
public void Erzeuge(string source, string savepath,string filename, Hashtable daten,List<BilderObject> bilderObjects,DataTable tableContents, bool erzeugeDOC = false , bool erzeugePDF = true)
|
public void Erzeuge(string source, string savepath,string filename, Hashtable daten,List<BilderObject> bilderObjects,DataTable tableContents, bool erzeugeDOC = false , bool erzeugePDF = true)
|
||||||
{
|
{
|
||||||
|
|
||||||
if (bilderObjects != null)
|
if (bilderObjects != null)
|
||||||
{
|
{
|
||||||
_listImages = new List<Image>();
|
_listImages = new List<Image>();
|
||||||
|
|||||||
@@ -32,35 +32,44 @@
|
|||||||
<WarningLevel>4</WarningLevel>
|
<WarningLevel>4</WarningLevel>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Reference Include="Syncfusion.Compression.Base, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Chart.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.Compression.Base.17.1.0.50\lib\net46\Syncfusion.Compression.Base.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Chart.Base.17.2.0.34\lib\net46\Syncfusion.Chart.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.Compression.Portable, Version=17.1451.0.50, Culture=neutral, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Chart.Windows, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.Xamarin.Compression.17.1.0.50\lib\netstandard2.0\Syncfusion.Compression.Portable.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Chart.Windows.17.2.0.34\lib\net46\Syncfusion.Chart.Windows.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.Core.WinForms, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Compression.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.Core.WinForms.17.1.0.50\lib\net46\Syncfusion.Core.WinForms.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Compression.Base.17.2.0.34\lib\net46\Syncfusion.Compression.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.DocIO.Base, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Compression.Portable, Version=17.2451.0.34, Culture=neutral, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.DocIO.WinForms.17.1.0.50\lib\net46\Syncfusion.DocIO.Base.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Xamarin.Compression.17.2.0.34\lib\netstandard2.0\Syncfusion.Compression.Portable.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.DocToPdfConverter.Base, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Core.WinForms, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.DocToPDFConverter.WinForms.17.1.0.50\lib\net46\Syncfusion.DocToPdfConverter.Base.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Core.WinForms.17.2.0.34\lib\net46\Syncfusion.Core.WinForms.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.Licensing, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=632609b4d040f6b4, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.DocIO.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.Licensing.17.1.0.50\lib\net46\Syncfusion.Licensing.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.DocIO.WinForms.17.2.0.34\lib\net46\Syncfusion.DocIO.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.OfficeChart.Base, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.DocToPdfConverter.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.OfficeChart.Base.17.1.0.50\lib\net46\Syncfusion.OfficeChart.Base.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.DocToPDFConverter.WinForms.17.2.0.34\lib\net46\Syncfusion.DocToPdfConverter.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.Pdf.Base, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Grouping.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.Pdf.WinForms.17.1.0.50\lib\net46\Syncfusion.Pdf.Base.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Grouping.Base.17.2.0.34\lib\net46\Syncfusion.Grouping.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.PdfViewer.Windows, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.Licensing, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=632609b4d040f6b4, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.PdfViewer.Windows.17.1.0.50\lib\net46\Syncfusion.PdfViewer.Windows.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.Licensing.17.2.0.34\lib\net46\Syncfusion.Licensing.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.Shared.Base, Version=17.1460.0.50, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
<Reference Include="Syncfusion.OfficeChart.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Syncfusion.Shared.Base.17.1.0.50\lib\net46\Syncfusion.Shared.Base.dll</HintPath>
|
<HintPath>..\packages\Syncfusion.OfficeChart.Base.17.2.0.34\lib\net46\Syncfusion.OfficeChart.Base.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Syncfusion.Pdf.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Syncfusion.Pdf.WinForms.17.2.0.34\lib\net46\Syncfusion.Pdf.Base.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Syncfusion.PdfViewer.Windows, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Syncfusion.PdfViewer.Windows.17.2.0.34\lib\net46\Syncfusion.PdfViewer.Windows.dll</HintPath>
|
||||||
|
</Reference>
|
||||||
|
<Reference Include="Syncfusion.Shared.Base, Version=17.2460.0.34, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
||||||
|
<HintPath>..\packages\Syncfusion.Shared.Base.17.2.0.34\lib\net46\Syncfusion.Shared.Base.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Core" />
|
<Reference Include="System.Core" />
|
||||||
@@ -87,6 +96,7 @@
|
|||||||
<Compile Include="FrmPDFViewer.Designer.cs">
|
<Compile Include="FrmPDFViewer.Designer.cs">
|
||||||
<DependentUpon>FrmPDFViewer.cs</DependentUpon>
|
<DependentUpon>FrmPDFViewer.cs</DependentUpon>
|
||||||
</Compile>
|
</Compile>
|
||||||
|
<Compile Include="makeGraphic.cs" />
|
||||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
@@ -104,6 +114,7 @@
|
|||||||
</ProjectReference>
|
</ProjectReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<None Include="app.config" />
|
||||||
<None Include="packages.config" />
|
<None Include="packages.config" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ using System.Collections;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.ComponentModel;
|
using System.ComponentModel;
|
||||||
using System.Data;
|
using System.Data;
|
||||||
|
using System.Diagnostics;
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
@@ -41,6 +42,7 @@ namespace BerichtGen
|
|||||||
/// <param name="tableContent"></param>
|
/// <param name="tableContent"></param>
|
||||||
public FrmOptions(string firma, string vorlage, string speicherpfad,string filename, Hashtable grunddaten, List<BilderObject> bilderObjects, DataTable tableContent = null)
|
public FrmOptions(string firma, string vorlage, string speicherpfad,string filename, Hashtable grunddaten, List<BilderObject> bilderObjects, DataTable tableContent = null)
|
||||||
{
|
{
|
||||||
|
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
|
||||||
this.firma = firma;
|
this.firma = firma;
|
||||||
@@ -51,6 +53,7 @@ namespace BerichtGen
|
|||||||
this.tableContent = tableContent;
|
this.tableContent = tableContent;
|
||||||
this.source = Path.Combine("documents", firma, vorlage);
|
this.source = Path.Combine("documents", firma, vorlage);
|
||||||
this.filename = filename;
|
this.filename = filename;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Gen()
|
void Gen()
|
||||||
|
|||||||
15
BerichtGen/app.config
Normal file
15
BerichtGen/app.config
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<configuration>
|
||||||
|
<runtime>
|
||||||
|
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||||
|
<dependentAssembly>
|
||||||
|
<assemblyIdentity name="Syncfusion.Shared.Base" publicKeyToken="3d67ed1f87d44c89" culture="neutral" />
|
||||||
|
<bindingRedirect oldVersion="0.0.0.0-17.2460.0.34" newVersion="17.2460.0.34" />
|
||||||
|
</dependentAssembly>
|
||||||
|
<dependentAssembly>
|
||||||
|
<assemblyIdentity name="Syncfusion.Licensing" publicKeyToken="632609b4d040f6b4" culture="neutral" />
|
||||||
|
<bindingRedirect oldVersion="0.0.0.0-17.2460.0.34" newVersion="17.2460.0.34" />
|
||||||
|
</dependentAssembly>
|
||||||
|
</assemblyBinding>
|
||||||
|
</runtime>
|
||||||
|
</configuration>
|
||||||
105
BerichtGen/makeGraphic.cs
Normal file
105
BerichtGen/makeGraphic.cs
Normal file
@@ -0,0 +1,105 @@
|
|||||||
|
using SanShared;
|
||||||
|
using Syncfusion.Windows.Forms.Chart;
|
||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Diagnostics;
|
||||||
|
using System.Drawing;
|
||||||
|
using System.IO;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace BerichtGen
|
||||||
|
{
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
public static class makeGraphic
|
||||||
|
{
|
||||||
|
private static ChartControl getGraph(List<UVcsvStrukture> input, string type)
|
||||||
|
{
|
||||||
|
Size size = new Size(600, 400);
|
||||||
|
|
||||||
|
ChartControl chartControl = new ChartControl();
|
||||||
|
chartControl.Size = size;
|
||||||
|
|
||||||
|
ChartAxis axis = chartControl.PrimaryYAxis;
|
||||||
|
|
||||||
|
|
||||||
|
ChartAxisLayout layout1 = new ChartAxisLayout();
|
||||||
|
|
||||||
|
|
||||||
|
layout1.Spacing = 12;
|
||||||
|
|
||||||
|
layout1.Axes.Add(axis);
|
||||||
|
|
||||||
|
|
||||||
|
chartControl.ChartArea.YLayouts.Add(layout1);
|
||||||
|
|
||||||
|
ChartSeries mychart = new ChartSeries(type, ChartSeriesType.Line);
|
||||||
|
|
||||||
|
|
||||||
|
int counter = 0;
|
||||||
|
|
||||||
|
foreach (UVcsvStrukture pars in input)
|
||||||
|
{
|
||||||
|
if (type.Equals("Temperatur"))
|
||||||
|
mychart.Points.Add(counter, pars.Temperatur);
|
||||||
|
else if (type.Equals("Druck"))
|
||||||
|
mychart.Points.Add(counter, pars.Druck);
|
||||||
|
else
|
||||||
|
throw new Exception("Kein gültiger Aufruf");
|
||||||
|
counter++;
|
||||||
|
}
|
||||||
|
|
||||||
|
mychart.YAxis = axis;
|
||||||
|
|
||||||
|
switch (type)
|
||||||
|
{
|
||||||
|
case "Temperatur":
|
||||||
|
axis.Title = "°C";
|
||||||
|
break;
|
||||||
|
|
||||||
|
case "Druck":
|
||||||
|
axis.Title = "[bar]";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
axis.TitleFont = new Font("Segeo UI", 14F);
|
||||||
|
|
||||||
|
|
||||||
|
chartControl.LegendsPlacement = ChartPlacement.Outside;
|
||||||
|
chartControl.LegendPosition = ChartDock.Bottom;
|
||||||
|
chartControl.LegendAlignment = ChartAlignment.Center;
|
||||||
|
chartControl.Title.Visible = false;
|
||||||
|
|
||||||
|
chartControl.Series.Add(mychart);
|
||||||
|
chartControl.Skins = Skins.Metro;
|
||||||
|
|
||||||
|
axis.EdgeLabelsDrawingMode = ChartAxisEdgeLabelsDrawingMode.Shift;
|
||||||
|
|
||||||
|
|
||||||
|
return chartControl;
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// Erstellt die Drucksverlauf kurve
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="struktures"></param>
|
||||||
|
/// <param name="destinationPath"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static bool GetGraphics(List<UVcsvStrukture> struktures,string destinationPath)
|
||||||
|
{
|
||||||
|
Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MTIwMjk0QDMxMzcyZTMyMmUzME9BaCs3SUNHQklVTE11ZTZnTGdQcmk2eU4xeWphZDdMYkUrbytOTTRveXc9");
|
||||||
|
|
||||||
|
ChartControl tempChart = getGraph(struktures, "Temperatur");
|
||||||
|
if (tempChart == null) return false;
|
||||||
|
else
|
||||||
|
tempChart.SaveImage(Path.Combine(destinationPath, "linerGraph_temp.jpg"));
|
||||||
|
ChartControl druckChart = getGraph(struktures, "Druck");
|
||||||
|
if (druckChart == null) return false;
|
||||||
|
else
|
||||||
|
druckChart.SaveImage(Path.Combine(destinationPath, "linerGraph_druck.jpg"));
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,13 +1,16 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<packages>
|
<packages>
|
||||||
<package id="Syncfusion.Compression.Base" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Chart.Base" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Core.WinForms" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Chart.Windows" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.DocIO.WinForms" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Compression.Base" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.DocToPDFConverter.WinForms" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Core.WinForms" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Licensing" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.DocIO.WinForms" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.OfficeChart.Base" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.DocToPDFConverter.WinForms" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Pdf.WinForms" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Grouping.Base" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.PdfViewer.Windows" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Licensing" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Shared.Base" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.OfficeChart.Base" version="17.2.0.34" targetFramework="net472" />
|
||||||
<package id="Syncfusion.Xamarin.Compression" version="17.1.0.50" targetFramework="net472" />
|
<package id="Syncfusion.Pdf.WinForms" version="17.2.0.34" targetFramework="net472" />
|
||||||
|
<package id="Syncfusion.PdfViewer.Windows" version="17.2.0.34" targetFramework="net472" />
|
||||||
|
<package id="Syncfusion.Shared.Base" version="17.2.0.34" targetFramework="net472" />
|
||||||
|
<package id="Syncfusion.Xamarin.Compression" version="17.2.0.34" targetFramework="net472" />
|
||||||
</packages>
|
</packages>
|
||||||
@@ -7,20 +7,37 @@ using System.Threading.Tasks;
|
|||||||
|
|
||||||
namespace SanShared.Exceptions
|
namespace SanShared.Exceptions
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
public class DataBaseVersionMismatchException : Exception
|
public class DataBaseVersionMismatchException : Exception
|
||||||
{
|
{
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
public DataBaseVersionMismatchException()
|
public DataBaseVersionMismatchException()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="message"></param>
|
||||||
public DataBaseVersionMismatchException(string message) : base(message)
|
public DataBaseVersionMismatchException(string message) : base(message)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="message"></param>
|
||||||
|
/// <param name="innerException"></param>
|
||||||
public DataBaseVersionMismatchException(string message, Exception innerException) : base(message, innerException)
|
public DataBaseVersionMismatchException(string message, Exception innerException) : base(message, innerException)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
/// <summary>
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="info"></param>
|
||||||
|
/// <param name="context"></param>
|
||||||
protected DataBaseVersionMismatchException(SerializationInfo info, StreamingContext context) : base(info, context)
|
protected DataBaseVersionMismatchException(SerializationInfo info, StreamingContext context) : base(info, context)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,11 +7,11 @@
|
|||||||
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Syncfusion.Shared.Base" publicKeyToken="3d67ed1f87d44c89" culture="neutral" />
|
<assemblyIdentity name="Syncfusion.Shared.Base" publicKeyToken="3d67ed1f87d44c89" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-17.1460.0.49" newVersion="17.1460.0.49" />
|
<bindingRedirect oldVersion="0.0.0.0-17.2460.0.34" newVersion="17.2460.0.34" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
<dependentAssembly>
|
<dependentAssembly>
|
||||||
<assemblyIdentity name="Syncfusion.Licensing" publicKeyToken="632609b4d040f6b4" culture="neutral" />
|
<assemblyIdentity name="Syncfusion.Licensing" publicKeyToken="632609b4d040f6b4" culture="neutral" />
|
||||||
<bindingRedirect oldVersion="0.0.0.0-17.1460.0.49" newVersion="17.1460.0.49" />
|
<bindingRedirect oldVersion="0.0.0.0-17.2460.0.34" newVersion="17.2460.0.34" />
|
||||||
</dependentAssembly>
|
</dependentAssembly>
|
||||||
</assemblyBinding>
|
</assemblyBinding>
|
||||||
</runtime>
|
</runtime>
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ namespace SanSystem
|
|||||||
if (dongle.CheckDongleVorhanden())
|
if (dongle.CheckDongleVorhanden())
|
||||||
{
|
{
|
||||||
dongle.CleanDongle();
|
dongle.CleanDongle();
|
||||||
Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense("MTA3MjIwQDMxMzcyZTMxMmUzMFpGMWh4K3R1aUZERnM0WVQvOTdOK2pkSERKTlZKNzFTcUJZY1pZQ2ZHL1k9");
|
|
||||||
Global.Instance.LoadLanguage();
|
Global.Instance.LoadLanguage();
|
||||||
Application.EnableVisualStyles();
|
Application.EnableVisualStyles();
|
||||||
Application.SetCompatibleTextRenderingDefault(false);
|
Application.SetCompatibleTextRenderingDefault(false);
|
||||||
|
|||||||
@@ -46,46 +46,6 @@
|
|||||||
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
<Reference Include="Newtonsoft.Json, Version=11.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||||
<HintPath>..\packages\Newtonsoft.Json.11.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
<HintPath>..\packages\Newtonsoft.Json.11.0.2\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||||
</Reference>
|
</Reference>
|
||||||
<Reference Include="Syncfusion.Chart.Base, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Chart.Base.17.1.0.49\lib\net46\Syncfusion.Chart.Base.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Chart.Windows, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Chart.Windows.17.1.0.49\lib\net46\Syncfusion.Chart.Windows.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Core.WinForms, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Core.WinForms.17.1.0.49\lib\net46\Syncfusion.Core.WinForms.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Grid.Base, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Grid.Base.17.1.0.49\lib\net46\Syncfusion.Grid.Base.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Grid.Windows, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Grid.Windows.17.1.0.49\lib\net46\Syncfusion.Grid.Windows.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Licensing, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=632609b4d040f6b4, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Licensing.17.1.0.49\lib\net46\Syncfusion.Licensing.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.SfInput.WinForms, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.SfInput.WinForms.17.1.0.49\lib\net46\Syncfusion.SfInput.WinForms.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.SfSpellChecker.WPF, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.SfSpellChecker.WPF.17.1.0.49\lib\net46\Syncfusion.SfSpellChecker.WPF.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Shared.Base, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Shared.Base.17.1.0.49\lib\net46\Syncfusion.Shared.Base.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Shared.Windows, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Shared.Windows.17.1.0.49\lib\net46\Syncfusion.Shared.Windows.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.SpellChecker.Base, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.SpellChecker.Base.17.1.0.49\lib\net46\Syncfusion.SpellChecker.Base.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Tools.Base, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Tools.Base.17.1.0.49\lib\net46\Syncfusion.Tools.Base.dll</HintPath>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="Syncfusion.Tools.Windows, Version=17.1460.0.49, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89, processorArchitecture=MSIL">
|
|
||||||
<HintPath>..\packages\Syncfusion.Tools.Windows.17.1.0.49\lib\net46\Syncfusion.Tools.Windows.dll</HintPath>
|
|
||||||
<Private>True</Private>
|
|
||||||
</Reference>
|
|
||||||
<Reference Include="System" />
|
<Reference Include="System" />
|
||||||
<Reference Include="System.Core" />
|
<Reference Include="System.Core" />
|
||||||
<Reference Include="System.Design" />
|
<Reference Include="System.Design" />
|
||||||
|
|||||||
@@ -13,8 +13,8 @@ using System.IO;
|
|||||||
using SanShared;
|
using SanShared;
|
||||||
using FluentFTP;
|
using FluentFTP;
|
||||||
using System.Collections;
|
using System.Collections;
|
||||||
using Syncfusion.Windows.Forms.Chart;
|
|
||||||
using CSVParser;
|
using CSVParser;
|
||||||
|
using BerichtGen;
|
||||||
|
|
||||||
namespace SanSystem
|
namespace SanSystem
|
||||||
{
|
{
|
||||||
@@ -213,71 +213,7 @@ namespace SanSystem
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private static ChartControl getGraph(List<UVcsvStrukture> input,string type)
|
|
||||||
{
|
|
||||||
Size size = new Size(600, 400);
|
|
||||||
|
|
||||||
ChartControl chartControl = new ChartControl();
|
|
||||||
chartControl.Size = size;
|
|
||||||
|
|
||||||
ChartAxis axis = chartControl.PrimaryYAxis;
|
|
||||||
|
|
||||||
|
|
||||||
ChartAxisLayout layout1 = new ChartAxisLayout();
|
|
||||||
|
|
||||||
|
|
||||||
layout1.Spacing = 12;
|
|
||||||
|
|
||||||
layout1.Axes.Add(axis);
|
|
||||||
|
|
||||||
|
|
||||||
chartControl.ChartArea.YLayouts.Add(layout1);
|
|
||||||
|
|
||||||
ChartSeries mychart = new ChartSeries(type, ChartSeriesType.Line);
|
|
||||||
|
|
||||||
|
|
||||||
int counter = 0;
|
|
||||||
|
|
||||||
foreach (UVcsvStrukture pars in input)
|
|
||||||
{
|
|
||||||
if (type.Equals("Temperatur"))
|
|
||||||
mychart.Points.Add(counter, pars.Temperatur);
|
|
||||||
else if (type.Equals("Druck"))
|
|
||||||
mychart.Points.Add(counter, pars.Druck);
|
|
||||||
else
|
|
||||||
throw new Exception("Kein gültiger Aufruf");
|
|
||||||
counter++;
|
|
||||||
}
|
|
||||||
|
|
||||||
mychart.YAxis = axis;
|
|
||||||
|
|
||||||
switch(type)
|
|
||||||
{
|
|
||||||
case "Temperatur":
|
|
||||||
axis.Title = "°C";
|
|
||||||
break;
|
|
||||||
|
|
||||||
case "Druck":
|
|
||||||
axis.Title = "[bar]";
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
axis.TitleFont = new Font("Segeo UI", 14F);
|
|
||||||
|
|
||||||
|
|
||||||
chartControl.LegendsPlacement = ChartPlacement.Outside;
|
|
||||||
chartControl.LegendPosition = ChartDock.Bottom;
|
|
||||||
chartControl.LegendAlignment = ChartAlignment.Center;
|
|
||||||
chartControl.Title.Visible = false;
|
|
||||||
|
|
||||||
chartControl.Series.Add(mychart);
|
|
||||||
chartControl.Skins = Skins.Metro;
|
|
||||||
|
|
||||||
axis.EdgeLabelsDrawingMode = ChartAxisEdgeLabelsDrawingMode.Shift;
|
|
||||||
|
|
||||||
|
|
||||||
return chartControl;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
private bool AccessCSV()
|
private bool AccessCSV()
|
||||||
@@ -295,15 +231,8 @@ namespace SanSystem
|
|||||||
|
|
||||||
inliner.AnfangAushaertung = struktures.Select(x => x.Zeitstempel).Min();
|
inliner.AnfangAushaertung = struktures.Select(x => x.Zeitstempel).Min();
|
||||||
inliner.EndeAushaertung = struktures.Select(x => x.Zeitstempel).Max();
|
inliner.EndeAushaertung = struktures.Select(x => x.Zeitstempel).Max();
|
||||||
ChartControl tempChart = getGraph(struktures,"Temperatur");
|
|
||||||
if (tempChart == null) return false;
|
return makeGraphic.GetGraphics(struktures, destinationPath);
|
||||||
else
|
|
||||||
tempChart.SaveImage(Path.Combine(destinationPath, "linerGraph_temp.jpg"));
|
|
||||||
ChartControl druckChart = getGraph(struktures, "Druck");
|
|
||||||
if (druckChart == null) return false;
|
|
||||||
else
|
|
||||||
druckChart.SaveImage(Path.Combine(destinationPath, "linerGraph_druck.jpg"));
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void btn_create_protokol_Click(object sender, EventArgs e)
|
private void btn_create_protokol_Click(object sender, EventArgs e)
|
||||||
|
|||||||
Reference in New Issue
Block a user