blob: 0e1250d00da1e2526538c301ce7f5147b97b0476 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
using RehauSku.Interface;
using System;
namespace RehauSku.PriceListTools
{
internal class ConvertTool : AbstractTool
{
private SourcePriceList Current;
public void GetCurrent()
{
try
{
Current = new SourcePriceList(ExcelApp.ActiveWorkbook);
}
catch (Exception exception)
{
System.Windows.Forms.MessageBox.Show
(exception.Message,
"Ошибка распознавания",
System.Windows.Forms.MessageBoxButtons.OK,
System.Windows.Forms.MessageBoxIcon.Information);
throw exception;
}
}
public void FillTarget()
{
ProgressBar = new ProgressBar("Заполняю строки...", Current.PositionAmount.Count);
ResultBar = new ResultBar();
foreach (var kvp in Current.PositionAmount)
{
FillPositionAmountToColumns(kvp, TargetFile.amountCell.Column);
ProgressBar.Update();
}
FilterByAmount();
ResultBar.Update();
//Dialog.SaveWorkbookAs();
ExcelApp.StatusBar = false;
}
}
}
|