Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
DanWBR committed Jan 24, 2024
1 parent a8cd58a commit 2aef2e8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
5 changes: 3 additions & 2 deletions DWSIM/Controls/TwoDimChartControl.vb
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ Imports DWSIM.CrossPlatform.UI.Controls.ReoGrid
Imports OxyPlot
Imports OxyPlot.Series
Imports System.Linq
Imports System.IO

Public Class TwoDimChartControl

Expand Down Expand Up @@ -159,7 +160,7 @@ Public Class TwoDimChartControl
Dim sheet = Spreadsheet.GetWorksheetByName(item.Split("!")(0))
If Not sheet Is Nothing Then
#If LINUX Then
Dim data As Object(,) = sheet.GetRangeData(New RangePosition(item.Split("!")(1)))
Dim data As Object(,) = sheet.GetRangeData(New RangePosition(item.Split("!")(1)))
#Else
Dim data As Object(,) = sheet.GetRangeData(New unvell.ReoGrid.RangePosition(item.Split("!")(1)))
#End If
Expand Down Expand Up @@ -415,7 +416,7 @@ Public Class TwoDimChartControl
New List(Of FilePickerAllowedType) From {New FilePickerAllowedType(extension + " File", "*." + extension)})

If handler IsNot Nothing Then
Using stream As New IO.MemoryStream()
Using stream As New MemoryStream()
If extension = "PNG" Then
Dim exporter = New OxyPlot.WindowsForms.PngExporter() With {.Background = OxyPlot.OxyColors.White, .Width = PlotView1.Width, .Height = PlotView1.Height}
exporter.Export(Chart.PlotModel, stream)
Expand Down
4 changes: 1 addition & 3 deletions DWSIM/DWSIM.vbproj
Original file line number Diff line number Diff line change
Expand Up @@ -547,9 +547,7 @@
<Compile Include="Controls\TwoDimChartControl.Designer.vb">
<DependentUpon>TwoDimChartControl.vb</DependentUpon>
</Compile>
<Compile Include="Controls\TwoDimChartControl.vb">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Controls\TwoDimChartControl.vb" />
<Compile Include="Controls\ListItem.Designer.vb">
<DependentUpon>ListItem.vb</DependentUpon>
</Compile>
Expand Down

0 comments on commit 2aef2e8

Please sign in to comment.