This commit is contained in:
parent
85d0e02a4f
commit
63ebe985f1
@ -371,12 +371,19 @@ namespace DataLoader
|
|||||||
foreach (DataRow drt in dtt.Rows)
|
foreach (DataRow drt in dtt.Rows)
|
||||||
{
|
{
|
||||||
// get from/to seq, subtract off '0' to get stepnumber.
|
// get from/to seq, subtract off '0' to get stepnumber.
|
||||||
|
// The 'oldto' field stores which foldout section these steps go
|
||||||
|
// to. However, if reset, the 'oldto' may not contain a reference
|
||||||
|
// to a foldout, i.e. may contain 'junk' data. Only add the
|
||||||
|
// reference to the dictionary if it's a foldout.
|
||||||
int fromStep = drt["FROMSEQUEN"].ToString()[1] - '0';
|
int fromStep = drt["FROMSEQUEN"].ToString()[1] - '0';
|
||||||
int toStep = drt["TOSEQUENCE"].ToString()[1] - '0';
|
int toStep = drt["TOSEQUENCE"].ToString()[1] - '0';
|
||||||
string foldSeq = drt["OLDTO"].ToString().Substring(0, 2);
|
string foldSeq = drt["OLDTO"].ToString().Substring(0, 2);
|
||||||
|
if (foldSeq[1] == 'F')
|
||||||
|
{
|
||||||
for (int istp = fromStep; istp <= toStep; istp++)
|
for (int istp = fromStep; istp <= toStep; istp++)
|
||||||
stpFoldSeq.Add(istp, foldSeq);
|
stpFoldSeq.Add(istp, foldSeq);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
ds.Dispose();
|
ds.Dispose();
|
||||||
da.Dispose();
|
da.Dispose();
|
||||||
// now read in the HLS's and set their config to the appropriate foldout:
|
// now read in the HLS's and set their config to the appropriate foldout:
|
||||||
@ -384,8 +391,15 @@ namespace DataLoader
|
|||||||
foreach (int hlsItemId in FloatingFoldoutHLS)
|
foreach (int hlsItemId in FloatingFoldoutHLS)
|
||||||
{
|
{
|
||||||
using (Item itmF = Item.Get(hlsItemId))
|
using (Item itmF = Item.Get(hlsItemId))
|
||||||
|
{
|
||||||
|
// be sure that the dictionaries contain the key.
|
||||||
|
// Some data may be 'corrupt' and not have the appropriate linkages
|
||||||
|
// to floating foldouts.
|
||||||
|
if (stpFoldSeq.ContainsKey(cnt))
|
||||||
{
|
{
|
||||||
string fldstr = stpFoldSeq[cnt];
|
string fldstr = stpFoldSeq[cnt];
|
||||||
|
if (FoldoutStpSeq.ContainsKey(fldstr))
|
||||||
|
{
|
||||||
int fldItemId = FoldoutStpSeq[fldstr];
|
int fldItemId = FoldoutStpSeq[fldstr];
|
||||||
ConfigInfo ciFold = new ConfigInfo(itmF.MyContent.Config);
|
ConfigInfo ciFold = new ConfigInfo(itmF.MyContent.Config);
|
||||||
ciFold.AddItem("Step", "FloatingFoldout", fldItemId.ToString());
|
ciFold.AddItem("Step", "FloatingFoldout", fldItemId.ToString());
|
||||||
@ -394,6 +408,8 @@ namespace DataLoader
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
frmMain.AddError(ex, "Error resolving Floating Foldout Data '{0}'", ProcNumber);
|
frmMain.AddError(ex, "Error resolving Floating Foldout Data '{0}'", ProcNumber);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user