diff --git a/PROMS/VEPROMS.CSLA.Library/Config/DocVersionConfig.cs b/PROMS/VEPROMS.CSLA.Library/Config/DocVersionConfig.cs index 353f6418..cf11dcfd 100644 --- a/PROMS/VEPROMS.CSLA.Library/Config/DocVersionConfig.cs +++ b/PROMS/VEPROMS.CSLA.Library/Config/DocVersionConfig.cs @@ -367,7 +367,7 @@ namespace VEPROMS.CSLA.Library [TypeConverter(typeof(EnumDescConverter))] public enum PrintChangeBar : int { - [Description("Select Before Printing")] + [Description("No Default, Select Before Printing")] SelectBeforePrinting = 0, [Description("Without Change Bars")] Without, diff --git a/PROMS/VEPROMS.CSLA.Library/Config/ProcConfig.cs b/PROMS/VEPROMS.CSLA.Library/Config/ProcConfig.cs index 0217e9b8..2cfcbc5b 100644 --- a/PROMS/VEPROMS.CSLA.Library/Config/ProcConfig.cs +++ b/PROMS/VEPROMS.CSLA.Library/Config/ProcConfig.cs @@ -56,7 +56,8 @@ namespace VEPROMS.CSLA.Library if (args.AncestorLookup || ParentLookup) { string retval; - ProcedureInfo proc = _Procedure.MyProcedureInfo; + //ProcedureInfo proc = _Procedure.MyProcedureInfo; + ProcedureInfo proc = _Procedure != null ? _Procedure.MyProcedureInfo : _ProcedureInfo; while (proc.ActiveParent.GetType() == typeof(ProcedureInfo)) { retval = proc.ProcedureConfig.GetValue(args.Group, args.Item); @@ -96,6 +97,8 @@ namespace VEPROMS.CSLA.Library string xml = procedureInfo.MyContent.Config; if (xml == string.Empty) xml = ""; _Xp = new XMLProperties(xml); + _Xp.AncestorLookup = true; + if (procedureInfo.ActiveParent != null) _Xp.LookInAncestor += new XMLPropertiesEvent(Xp_LookInAncestorFolder); } public ProcedureConfig(string xml) { diff --git a/PROMS/VEPROMS.CSLA.Library/Config/StepConfig.cs b/PROMS/VEPROMS.CSLA.Library/Config/StepConfig.cs index 7e0a4a5a..67bfed27 100644 --- a/PROMS/VEPROMS.CSLA.Library/Config/StepConfig.cs +++ b/PROMS/VEPROMS.CSLA.Library/Config/StepConfig.cs @@ -173,6 +173,25 @@ namespace VEPROMS.CSLA.Library OnPropertyChanged("Step_CBOverride"); } } + public string Step_MultipleChangeID + { + get + { + string s = _Xp["Step", "MultipleChangeID"]; + + if (s == string.Empty) return null; + return s; + } + set + { + string s = _Xp["Step", "MultipleChangeID"]; + + if (value != null && value.ToString() == s) return; + if (value == null && s != null) _Xp["Step", "MultipleChangeID"] = null; + else _Xp["Step", "MultipleChangeID"] = value.ToString(); + OnPropertyChanged("Step_MultipleChangeID"); + } + } #endregion } } diff --git a/PROMS/VEPROMS.CSLA.Library/Config/XMLProperties.cs b/PROMS/VEPROMS.CSLA.Library/Config/XMLProperties.cs index 741af4cf..24b3164d 100644 --- a/PROMS/VEPROMS.CSLA.Library/Config/XMLProperties.cs +++ b/PROMS/VEPROMS.CSLA.Library/Config/XMLProperties.cs @@ -18,6 +18,14 @@ namespace VEPROMS.CSLA.Library return string.Empty; } #endregion + private bool _AncestorLookup=false; + + public bool AncestorLookup + { + get { return _AncestorLookup; } + set { _AncestorLookup = value; } + } + #region Constructors public XMLProperties() { @@ -83,11 +91,11 @@ namespace VEPROMS.CSLA.Library get { if (_ParentLookup) - return OnLookInAncestor(this, new XMLPropertiesArgs(group, item)); + return OnLookInAncestor(this, new XMLPropertiesArgs(group, item, AncestorLookup)); XmlNode xn = GetGroup(group); - if (xn == null) return OnLookInAncestor(this,new XMLPropertiesArgs(group,item)); + if (xn == null) return OnLookInAncestor(this, new XMLPropertiesArgs(group, item, AncestorLookup)); XmlNode xa = GetItem(xn, item); - if (xa == null) return OnLookInAncestor(this, new XMLPropertiesArgs(group, item)); + if (xa == null) return OnLookInAncestor(this, new XMLPropertiesArgs(group, item, AncestorLookup)); return xa.InnerText; } set diff --git a/PROMS/VEPROMS/PrintMSWord/frmPrintMsWord.cs b/PROMS/VEPROMS/PrintMSWord/frmPrintMsWord.cs index 5ed7c952..fa155b2f 100644 --- a/PROMS/VEPROMS/PrintMSWord/frmPrintMsWord.cs +++ b/PROMS/VEPROMS/PrintMSWord/frmPrintMsWord.cs @@ -75,10 +75,12 @@ namespace PrintMSWord _ElapsedTime = new Dictionary(); DateTime tStart = DateTime.Now; string pdfFile = pp.Print(@"C:\TEMP\32Bit", _MyProms2010Print, null, this); + DateTime tEnd = DateTime.Now; _ElapsedTime.Add(PromsPrinterStatusType.Total, DateTime.Now - tStart); MyStatus = pdfFile + " created."; this.Cursor = saveCursor; ShowElapsedTime(); + MyStatus = string.Format("{0} created in {1:0.} milliseconds",pdfFile,(TimeSpan.FromTicks(tEnd.Ticks - tStart.Ticks).TotalMilliseconds)); } private void ShowElapsedTime() {