B2020-125: View of Consistency check report displaying error message and crashing

This commit is contained in:
2020-09-22 16:21:02 +00:00
parent c762960ddd
commit 59cb56ca88
2 changed files with 21 additions and 4 deletions

View File

@@ -83,10 +83,17 @@ namespace VEPROMS.CSLA.Library
foreach (ROCheck roc in MyDifferences.ROConsistency.MyROChecks)
{
ROFSTLookup.rochild rocc = lu.GetRoChild12(roc.ROID);
if(rocc.type == 1)
sb.Append(string.Format(" {0} - Old Value: {1} - New Value: {2}\r\n", lu.GetROTitle(roc.ROID), roc.OldROValue, roc.ROValue));
if (rocc.ID == -1) // B2020-125: View of Consistency check report displaying error message and crashing.
{
sb.Append(string.Format(" {0}\r\n", lu.GetROTitle(roc.ROID)));
}
else
sb.Append(string.Format(" {0} - Value has changed.\r\n", lu.GetROTitle(roc.ROID)));
{
if (rocc.type == 1)
sb.Append(string.Format(" {0} - Old Value: {1} - New Value: {2}\r\n", lu.GetROTitle(roc.ROID), roc.OldROValue, roc.ROValue));
else
sb.Append(string.Format(" {0} - Value has changed.\r\n", lu.GetROTitle(roc.ROID)));
}
}
}
//jcb