예제 #1
0
        private string buildErrorSummaryMessage()
        {
            if (null == ErroredTable)
            {
                return("No errored DataTable specified");
            }
            if (!ErroredTable.HasErrors)
            {
                return("No Row Errors reported in DataTable=[" + ErroredTable.TableName + "]");
            }

            foreach (DataRow row in ErroredTable.GetErrors())
            {
                recordColumnsInError(row);
                recordRowsInError(row);
            }

            StringBuilder sb = new StringBuilder();

            appendSummaryIntro(sb);
            appendErroredColumns(sb);
            appendRowErrors(sb);

            return(sb.ToString());
        }
예제 #2
0
 private void appendSummaryIntro(StringBuilder sb)
 {
     sb.AppendFormat("Errors reported for {1} [{2}]{0}", Environment.NewLine, ErroredTable.GetType().FullName, ErroredTable.TableName);
 }