RhSolutions-AddIn/RhSolutions.AddIn/Controllers/ConvertTool.cs
2023-03-22 08:36:13 +03:00

30 lines
841 B
C#

using RhSolutions.Models;
namespace RhSolutions.Controllers
{
internal class ConvertTool : ToolBase
{
private SourcePriceList Current { get; set; }
public ConvertTool()
{
Current = new SourcePriceList(ExcelApp.ActiveWorkbook);
}
public override void FillTarget()
{
using (ProgressBar = new ProgressBar("Заполняю строки...", Current.PositionAmount.Count))
using (ResultBar = new ResultBar())
{
foreach (var kvp in Current.PositionAmount)
{
FillPositionAmountToColumns(kvp, TargetFile.AmountCell.Column);
ProgressBar.Update();
}
FilterByAmount();
ResultBar.Update();
}
}
}
}