diff --git a/PROMS/DataLoader/TransitionFixer.cs b/PROMS/DataLoader/TransitionFixer.cs index bbed67b7..5cd9acf0 100644 --- a/PROMS/DataLoader/TransitionFixer.cs +++ b/PROMS/DataLoader/TransitionFixer.cs @@ -79,7 +79,7 @@ namespace DataLoader { Status = string.Format("Processing {0} of {1} steps", ++i, myList.Count); MyStepRTB.ViewRTB = false; - string originalText = item.MyContent.Text; + //string originalText = item.MyContent.Text; string updatedText = item.MyContent.Text; //if (item.ItemID == 1850) // Console.WriteLine("HERE"); @@ -100,11 +100,18 @@ namespace DataLoader } } } - MyStepRTB.MyItemInfo = item; - MyStepRTB.SaveText(); - string afterText = item.MyContent.Text; - if (updatedText != afterText)//|| newStripped != afterText) - myProblems.RTBProblems.Add(item.ItemID, item.MyContent.ContentID, originalText, updatedText, MyStepRTB.Rtf, afterText, item.Path); + using (Content c = item.MyContent.Get()) + { + c.Text = updatedText; + c.Save(); + } + //MyStepRTB.MyItemInfo = item; + //MyStepRTB.SaveText(); + //string afterText = item.MyContent.Text; + //updatedText = updatedText.Replace(@"\u160?", @"\'a0"); + // aftertext is 'newrtf' + //if (updatedText != afterText)//|| newStripped != afterText) + // myProblems.RTBProblems.Add(item.ItemID, item.MyContent.ContentID, originalText, updatedText, MyStepRTB.Rtf, afterText, item.Path); } //#if DEBUG else if (VlnSettings.DebugMode) @@ -113,10 +120,10 @@ namespace DataLoader } //#endif } - Status = "Saving problems"; - ErrorCount = myProblems.RTBProblems.Count; - //myProblems.Save(@"C:\temp\RTBProblems.xml"); - myProblems.Save(_LogPath + @"\RTBProblems.xml"); + //Status = "Saving problems"; + //ErrorCount = myProblems.RTBProblems.Count; + ////myProblems.Save(@"C:\temp\RTBProblems.xml"); + //myProblems.Save(_LogPath + @"\RTBProblems.xml"); Status = "Done comparing"; } diff --git a/PROMS/DataLoader/Transitions.cs b/PROMS/DataLoader/Transitions.cs index ce8b964f..9c33c8bf 100644 --- a/PROMS/DataLoader/Transitions.cs +++ b/PROMS/DataLoader/Transitions.cs @@ -101,10 +101,6 @@ namespace DataLoader } else { - // if the type == 0, i.e. procedure with optional step number and the procedure does not include - // the default A0 section, point to the procedure: - if (itype == 0 && thekey.EndsWith("A0")) // may have to process these at end? - Console.WriteLine("here"); if (itype > 6) itype--; // Corrected to match transformat table (16-bit skips type 6 because it's an outside transition) if (dicTrans_ItemDone.ContainsKey(thekey)) {