From afebd40e72b57e93f702923b159b044928396957 Mon Sep 17 00:00:00 2001 From: Kathy Date: Wed, 24 Aug 2011 11:45:35 +0000 Subject: [PATCH] --- PROMS/VEPROMS.CSLA.Library/Extension/ContentExt.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/PROMS/VEPROMS.CSLA.Library/Extension/ContentExt.cs b/PROMS/VEPROMS.CSLA.Library/Extension/ContentExt.cs index 11e182b8..a5e89098 100644 --- a/PROMS/VEPROMS.CSLA.Library/Extension/ContentExt.cs +++ b/PROMS/VEPROMS.CSLA.Library/Extension/ContentExt.cs @@ -19,7 +19,7 @@ namespace VEPROMS.CSLA.Library public void FixTransitionText(TransitionInfo tran) { string transText = tran.ResolvePathTo(); - string lookFor = string.Format(@"", tran.TranType, tran.TransitionID); + string lookFor = string.Format(@"", tran.TranType, tran.TransitionID); //string lookFor = string.Format(@"", tran.TranType, tran.TransitionID); Match m = Regex.Match(Text, lookFor); if (m != null && m.Groups.Count > 1) @@ -31,7 +31,7 @@ namespace VEPROMS.CSLA.Library // see if there is a grid to update too. if (tran.MyContent.MyGrid != null) { - string lookForXml = string.Format(@"<START\](\\[^v \\]+)*\\v0(\\[^v \\]+)* ([^#]*?)(\\[^v \\]+)*\\v(\\[^v \\]+)* #Link:Transition[^:]*?:{0} {1}( [0-9]*){{1,2}}\[END>", tran.TranType, tran.TransitionID); + string lookForXml = string.Format(@"<START\](\\[^v \\]+)*\\v0(\\[^v \\]+)* ([^#]*?)(\\[^v'? \\]+)*\\v(\\[^v \\]+)* #Link:Transition[^:]*?:{0} {1}( [0-9]*){{1,2}}\[END>", tran.TranType, tran.TransitionID); Match mg = Regex.Match(MyGrid.Data, lookForXml); if (mg != null && mg.Groups.Count > 1) { @@ -41,9 +41,9 @@ namespace VEPROMS.CSLA.Library } } } - public void FixContentText(RoUsageInfo rousg, ROFSTLookup.rochild roch, ROFstInfo origROFstInfo) // string newvalue) + public void FixContentText(RoUsageInfo rousg, string value, int rotype, ROFstInfo origROFstInfo) // string newvalue) { - string newvalue = roch.value; + string newvalue = value; string findLink = @""; MatchCollection ms = Regex.Matches(Text, findLink); string lookFor = string.Format(@"", rousg.ROUsageID); @@ -64,7 +64,7 @@ namespace VEPROMS.CSLA.Library // see if there is a grid to update too. if (rousg.MyContent.MyGrid != null) { - if (roch.type == (int)E_ROValueType.Table) // if change in rotable data... + if (rotype == (int)E_ROValueType.Table) // if change in rotable data... { List retlist = origROFstInfo.OnROTableUpdate(this, new ROFstInfoROTableUpdateEventArgs(newvalue, MyGrid.Data)); if (Text != retlist[0]) Text = retlist[0]; @@ -78,7 +78,7 @@ namespace VEPROMS.CSLA.Library MatchCollection msg = Regex.Matches(MyGrid.Data, findLinkXml); foreach (Match mmg in msg) { - int offset = mmg.Index; + int offset = 0; // crashed in substring line below if using mmg.Index; Set to 0 and it worked - KBR. Match mg = Regex.Match(MyGrid.Data, lookForXml); if (mg != null && mg.Groups.Count > 1) {