Added Progress Bar output

This commit is contained in:
Rich
2015-02-10 15:50:12 +00:00
parent ea42dd8795
commit 7d2273d0d1
3 changed files with 86 additions and 4 deletions

View File

@@ -7,11 +7,48 @@ using System.Text;
using System.Windows.Forms;
using System.IO;
using VEPROMS.CSLA.Library;
using DevComponents.DotNetBar;
namespace VEPROMS
{
public partial class frmRODbProperties : Form
{
private ProgressBarItem _ProgressBar = null;
public ProgressBarItem ProgressBar
{
get { return _ProgressBar; }
set { _ProgressBar = value; }
}
private void DoProgressBarRefresh(int value, int max, string text)
{
if (ProgressBar == null) return;
ProgressBar.Value = value;
ProgressBar.Maximum = max;
ProgressBar.Text = text;
Application.DoEvents();
}
private string InitialProgressBarMessage
{
set
{
if (ProgressBar == null) return;
ProgressBar.Value = 100;
ProgressBar.Maximum = 100;
ProgressBar.Text = value;
Application.DoEvents();
}
}
private string FinalProgressBarMessage
{
set
{
if (ProgressBar == null) return;
ProgressBar.Value = 100;
ProgressBar.Maximum = 100;
ProgressBar.Text = value;
Application.DoEvents();
}
}
private Point _ParentLocation;
public Point ParentLocation
{
@@ -140,7 +177,7 @@ namespace VEPROMS
RODb newroDb = RODb.MakeRODb(ppRTxtName.Text, ppTxtPath.Text, "cstring", null);
RODbInfo newrdi = RODbInfo.Get(newroDb.RODbID);
newroDb.Save().Dispose();
ROFst rofst = ROFstInfo.AddRoFst(newrdi, _docVersion);
ROFst rofst = ROFstInfo.AddRoFst(newrdi, _docVersion, DoProgressBarRefresh);
DialogResult = DialogResult.OK;
Close();
}