aboutsummaryrefslogtreecommitdiff
path: root/src/PriceListTools/Source.cs
diff options
context:
space:
mode:
authorSergey Chebotar <s.chebotar@gmail.com>2022-02-02 10:23:50 +0300
committerSergey Chebotar <s.chebotar@gmail.com>2022-02-02 10:23:50 +0300
commit120eee0231d02e90d9d195ebc38327a58d4564a8 (patch)
treeed1819297d8825805dbeb15156a032b172e826b9 /src/PriceListTools/Source.cs
parent06799119fb83cb6b75721c5cf60f4051e50976a7 (diff)
Add Excel statusbar progress message
Diffstat (limited to 'src/PriceListTools/Source.cs')
-rw-r--r--src/PriceListTools/Source.cs4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/PriceListTools/Source.cs b/src/PriceListTools/Source.cs
index 7cf56be..fe5ee9b 100644
--- a/src/PriceListTools/Source.cs
+++ b/src/PriceListTools/Source.cs
@@ -3,6 +3,7 @@ using Microsoft.Office.Interop.Excel;
using System;
using System.Collections.Generic;
using System.Linq;
+using RehauSku.Interface;
namespace RehauSku.PriceListTools
{
@@ -39,6 +40,7 @@ namespace RehauSku.PriceListTools
public static List<Source> GetSourceLists(string[] files)
{
var ExcelApp = (Application)ExcelDnaUtil.Application;
+ ProgressBar bar = new ProgressBar(files.Length);
List<Source> sourceFiles = new List<Source>();
@@ -51,6 +53,7 @@ namespace RehauSku.PriceListTools
Source priceList = new Source(wb);
sourceFiles.Add(priceList);
wb.Close();
+ bar.DoProgress();
}
catch (Exception ex)
{
@@ -60,6 +63,7 @@ namespace RehauSku.PriceListTools
System.Windows.Forms.MessageBoxButtons.OK,
System.Windows.Forms.MessageBoxIcon.Information);
wb.Close();
+ bar.DoProgress();
}
ExcelApp.ScreenUpdating = true;
}