diff --git a/PROMS/DataLoader/LoadTreeDB.cs b/PROMS/DataLoader/LoadTreeDB.cs index c8ebab1a..36f6ae57 100644 --- a/PROMS/DataLoader/LoadTreeDB.cs +++ b/PROMS/DataLoader/LoadTreeDB.cs @@ -62,7 +62,9 @@ namespace DataLoader Folder fld = null; foreach (FolderInfo fi in fil) { - if (fi.Name.ToUpper() == name.ToUpper() && fi.Title.ToUpper() == title.ToUpper()) + string fi_Title = fi.Title.TrimEnd('\\'); + //if (fi.Name.ToUpper() == name.ToUpper() && fi.Title.ToUpper() == title.ToUpper()) + if (fi.Name.ToUpper() == name.ToUpper() && fi_Title.ToUpper() == title.ToUpper()) { fld = Folder.Get(fi.FolderID); return fld; diff --git a/PROMS/DataLoader/Sections.cs b/PROMS/DataLoader/Sections.cs index 6200d312..7bcb9b9e 100644 --- a/PROMS/DataLoader/Sections.cs +++ b/PROMS/DataLoader/Sections.cs @@ -31,6 +31,7 @@ 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) { + string missingFileName = ""; bool missingDocFile = false; //Console.WriteLine("before UpdateLabels"); frmMain.UpdateLabels(0, 1, 0); @@ -124,8 +125,11 @@ namespace DataLoader else { int num = Convert.ToInt32(stpseq[0]) - 64; - string thenum = num.ToString("d2"); - fname = string.Format("{0}\\rtffiles\\{1}.A{2}", pth, ProcFileName, thenum); + char prefix = 'A'; + prefix += (char)(num / 100); + int numpart = num % 100; + //string thenum = num.ToString("d2"); + fname = string.Format("{0}\\rtffiles\\{1}.{2}{3:D02}", pth, ProcFileName, prefix, numpart); Application.DoEvents(); string procnum = ""; using (ItemInfo ii = ItemInfo.Get(procitem.ItemID)) @@ -142,6 +146,7 @@ namespace DataLoader } Documentid = MissingDocument.DocID; missingDocFile = true; + missingFileName = string.Format("{0}.{1}{2:D02}",ProcFileName, prefix, numpart); } } } @@ -204,7 +209,7 @@ namespace DataLoader if (missingDocFile) { ItemAnnotation ia = itm.ItemAnnotations.Add(MigrationErrorType); - ia.SearchText = "Missing File In Conversion"; + ia.SearchText = string.Format("Missing File: {0} In Conversion",missingFileName); ia.UserID = "Migration"; itm.Save(); }