DataLoader changes during development
This commit is contained in:
28
PROMS/DataLoader/ErrorReport.cs
Normal file
28
PROMS/DataLoader/ErrorReport.cs
Normal file
@@ -0,0 +1,28 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using VEPROMS.CSLA.Library;
|
||||
using Csla.Validation;
|
||||
|
||||
namespace DataLoader
|
||||
{
|
||||
public static class ErrorRpt
|
||||
{
|
||||
public static void ErrorReport(IVEHasBrokenRules mybr)
|
||||
{
|
||||
string smess = mybr.GetType().Name;
|
||||
IVEHasBrokenRules hbr = mybr.HasBrokenRules;
|
||||
if (hbr == null) smess += "\n Unknown Error";
|
||||
else
|
||||
{
|
||||
smess += "\n In object" + hbr.GetType().Name;
|
||||
foreach (BrokenRule br in hbr.BrokenRules)
|
||||
{
|
||||
smess += "\n" + br.Property + " - " + br.Description;
|
||||
}
|
||||
}
|
||||
MessageBox.Show(smess);
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user