From 1926a435b0d331ece464ef0d169a33e9d6f7bfcd Mon Sep 17 00:00:00 2001 From: Rich Date: Tue, 27 Sep 2016 19:35:36 +0000 Subject: [PATCH] Replace within a PC P/C PSI Value with the current unit number. --- PROMS/Volian.Print.Library/VlnSvgPageHelper.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/PROMS/Volian.Print.Library/VlnSvgPageHelper.cs b/PROMS/Volian.Print.Library/VlnSvgPageHelper.cs index 39e8d705..33fb9d9a 100644 --- a/PROMS/Volian.Print.Library/VlnSvgPageHelper.cs +++ b/PROMS/Volian.Print.Library/VlnSvgPageHelper.cs @@ -2008,12 +2008,16 @@ namespace Volian.Print.Library if (qindx == -1) { val = procConfig.GetValue("PSI", token.Substring(4, token.Length - 5)); - + if(val.Contains("")) // Replace with the current unit number + { + string unbr3 = MySection.MyDocVersion.DocVersionConfig.Unit_Number; + val=val.Replace("", unbr3??""); + } // MaxWidth is used to define width that the PSI text spans x-direction on page. If it is // defined, see if the text is too wide for a single line (SplitTextMaxWidth). The // AdjustTopMarginForMultLinePageListItem contains the y-adjustment that must be considered // in the TopMargin if the PSI text split onto more than one line. - if ((pageItem.MaxWidth??0)>0 || (pageItem.MaxWidthCurPage??0)>0) + if ((pageItem.MaxWidth ?? 0) > 0 || (pageItem.MaxWidthCurPage ?? 0) > 0) { int locwid = ((pageItem.MaxWidth??0)>0)?(int)pageItem.MaxWidth:(int)pageItem.MaxWidthCurPage; AdjustTopMarginForMultiLinePageListItems = SplitTextMaxWidth(svgGroup, pageItem, val, locwid, token, ref plstr);