Added new property "Process Only In Location" to limit the datasets that are converted when "Only Process this Procedure Set" is false.

Save the RevDate from the SET.DBF file.
This commit is contained in:
Rich 2012-11-05 21:54:31 +00:00
parent 4ed39bda97
commit 59b765e6d8
4 changed files with 29 additions and 8 deletions

View File

@ -80,6 +80,16 @@ namespace DataLoader
get { return _LoadApproved; } get { return _LoadApproved; }
set { _LoadApproved = value; } set { _LoadApproved = value; }
} }
private string _ProcessOnlyInLocation; // Folder
[Category("16-Bit Data")]
[DisplayName("Process Only In Location")]
[Description("Limit to folder or group of folders (otherwise all plants will be processed)")]
[EditorAttribute(typeof(UIFolderEditor), typeof(System.Drawing.Design.UITypeEditor))]
public string ProcessOnlyInLocation
{
get { return _ProcessOnlyInLocation; }
set { _ProcessOnlyInLocation = value; }
}
#endregion #endregion
#region Format Data #region Format Data
private string _FormatFolder; // Folder private string _FormatFolder; // Folder

View File

@ -171,6 +171,8 @@ namespace DataLoader
DirectoryInfo dir = new DirectoryInfo(frmMain.MySettings.ProcedureSetPath); DirectoryInfo dir = new DirectoryInfo(frmMain.MySettings.ProcedureSetPath);
_OnlyThisFolder = dir.Parent.FullName.ToUpper(); _OnlyThisFolder = dir.Parent.FullName.ToUpper();
} }
else if ((frmMain.MySettings.ProcessOnlyInLocation ?? "") != "")
_OnlyThisFolder = frmMain.MySettings.ProcessOnlyInLocation.ToUpper();
else else
_OnlyThisFolder = ""; _OnlyThisFolder = "";
} }

View File

@ -57,7 +57,13 @@ namespace DataLoader
ci = new ConfigInfo(null); ci = new ConfigInfo(null);
ci.AddItem("Procedure", "ProcCode", tstr); ci.AddItem("Procedure", "ProcCode", tstr);
} }
//load revdate
string tstr2 = dts.ToString("MM/dd/yyyy");
if (tstr2 != null && tstr2 != "")
{
if (ci == null) ci = new ConfigInfo(null);
ci.AddItem("Procedure", "RevDate", tstr2);
}
// Load in format data, i.e. default number of columns: // Load in format data, i.e. default number of columns:
string tstr1 = dr["Format"].ToString(); string tstr1 = dr["Format"].ToString();
if (tstr1 != null && tstr1 != "") if (tstr1 != null && tstr1 != "")

View File

@ -545,6 +545,8 @@ namespace DataLoader
MySettings.VESamFile = Properties.Settings.Default.VeSamFilename; MySettings.VESamFile = Properties.Settings.Default.VeSamFilename;
if (Properties.Settings.Default["DbfPathname"].ToString() != "") if (Properties.Settings.Default["DbfPathname"].ToString() != "")
MySettings.ProcedureSetPath = Properties.Settings.Default.DbfPathname; MySettings.ProcedureSetPath = Properties.Settings.Default.DbfPathname;
if (Properties.Settings.Default["ProcessOnlyInLocation"].ToString() != "")
MySettings.ProcessOnlyInLocation = Properties.Settings.Default.ProcessOnlyInLocation;
if (Properties.Settings.Default["BackupFileName"].ToString() != "") if (Properties.Settings.Default["BackupFileName"].ToString() != "")
MySettings.BackupFileName = Properties.Settings.Default.BackupFileName; MySettings.BackupFileName = Properties.Settings.Default.BackupFileName;
if (Properties.Settings.Default["BackupFolder"].ToString() != "") if (Properties.Settings.Default["BackupFolder"].ToString() != "")
@ -607,6 +609,7 @@ namespace DataLoader
Properties.Settings.Default.VePromsFilename = MySettings.VEPromsPath; Properties.Settings.Default.VePromsFilename = MySettings.VEPromsPath;
Properties.Settings.Default.VeSamFilename = MySettings.VESamFile; Properties.Settings.Default.VeSamFilename = MySettings.VESamFile;
Properties.Settings.Default.DbfPathname = MySettings.ProcedureSetPath; Properties.Settings.Default.DbfPathname = MySettings.ProcedureSetPath;
Properties.Settings.Default.ProcessOnlyInLocation = MySettings.ProcessOnlyInLocation;
Properties.Settings.Default.BackupFileName = MySettings.BackupFileName; Properties.Settings.Default.BackupFileName = MySettings.BackupFileName;
Properties.Settings.Default.BackupFolder = MySettings.BackupFolder; Properties.Settings.Default.BackupFolder = MySettings.BackupFolder;
Properties.Settings.Default.LogFileLoc = MySettings.LogFilePath; Properties.Settings.Default.LogFileLoc = MySettings.LogFilePath;