From bdc2d651e376acb02fa177c319496f4d1fd69e38 Mon Sep 17 00:00:00 2001 From: John Date: Thu, 12 Aug 2010 16:11:14 +0000 Subject: [PATCH] --- PROMS/DataLoader/Sections.cs | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/PROMS/DataLoader/Sections.cs b/PROMS/DataLoader/Sections.cs index 9a6387db..589c1586 100644 --- a/PROMS/DataLoader/Sections.cs +++ b/PROMS/DataLoader/Sections.cs @@ -30,10 +30,14 @@ namespace DataLoader private Dictionary dicOldToNew; private Item AddSection(Item procitem, string Number, string Title, string SecType, DateTime Dts, string Userid, ConfigInfo ci, string stpseq, string fmt, int libdocid, string pth, Item FromItem, FormatInfo activeFormat) { + //Console.WriteLine("before UpdateLabels"); frmMain.UpdateLabels(0, 1, 0); + //Console.WriteLine("after UpdateLabels"); try { + //Console.WriteLine("before activeFormat"); FormatInfo format = activeFormat; + //Console.WriteLine("after activeFormat"); // Tie the section to format used, this will add the format xml if it doesn't exist in // the database yet. Note that if there is no format at this level then none should @@ -302,6 +306,14 @@ namespace DataLoader } return menustr; } + private static Color _OverrideColor = Color.Red; + + public static Color OverrideColor + { + get { return Loader._OverrideColor; } + set { Loader._OverrideColor = value; } + } + private Item MigrateSection(Item procitem, string procnum, OleDbConnection cn, DataRowView dr, DataTable dt, Item FromItem, bool isSubSection, string pth, DocVersion docver, FormatInfo activeFormat,Content cont) { Int32 thesectid = 0; @@ -463,7 +475,9 @@ namespace DataLoader libDocid = dicLibDocRef[thekey]; } } + //Console.WriteLine("Before AddSection"); Item secitem = AddSection(procitem, num, title, stype, dts, init, ci, step + sequence, fmt, libDocid, pth, FromItem, sectFormat); + //Console.WriteLine("After AddSection"); if (secitem == null) throw (new Exception("Null parameter in AddSection")); if (cont != null) @@ -481,7 +495,7 @@ namespace DataLoader { using (DocumentInfo di = DocumentInfo.Get(secitem.MyContent.MyEntry.DocID)) { - MSWordToPDF.UpdateDocPdf(di, Color.Red); + MSWordToPDF.UpdateDocPdf(di, OverrideColor); } } } @@ -582,4 +596,4 @@ namespace DataLoader } } } -} \ No newline at end of file +}