diff --git a/PROMS/Volian.Print.Library/Pagination.cs b/PROMS/Volian.Print.Library/Pagination.cs index 8659262d..d19257e9 100644 --- a/PROMS/Volian.Print.Library/Pagination.cs +++ b/PROMS/Volian.Print.Library/Pagination.cs @@ -516,7 +516,6 @@ namespace Volian.Print.Library paraBreak = FindPageBreak(yStart, ySpaceOnCurPage-accountForCalvertAlarmConditionResponseFooter, yLowerLimit, myList, lastBreak, yPageSize - (myTopMsgSpace + SixLinesPerInch) - myBottomMsgSpace, myBottomMsgSpace,MyItemInfo.ActiveFormat.PlantFormat.FormatData.StepDataList[40].ContinueOnly); - float yLoc = ySpaceOnCurPage - (paraBreak.YOffset - (YTopMost + yTop)); //Console.WriteLine("Break at {0}", paraBreak.MyItemInfo.ShortPath);//Comment Out before release //if (lastBreak != null && lastBreak.MyItemInfo.InList(80091, 1985)) // Console.WriteLine("After 80091 {0}",paraBreak.ToString()); @@ -528,6 +527,7 @@ namespace Volian.Print.Library , MyItemInfo.ItemID, MyItemInfo.MyDocVersion.MyFolder.Name, MyItemInfo.ShortPath); break; } + float yLoc = ySpaceOnCurPage - (paraBreak.YOffset - (YTopMost + yTop)); if (yLoc <= 0) // Check where it would break if the space on the page was one line shorter { vlnParagraph paraBreak2 = FindPageBreak(yStart, ySpaceOnCurPage - (SixLinesPerInch + accountForCalvertAlarmConditionResponseFooter), yLowerLimit, @@ -698,7 +698,7 @@ namespace Volian.Print.Library RemoveProcessedParagraphs(myList, yTopNew - yTop); yTop = yTopNew; MyPageHelper.ParaBreaks.Add(paraBreak); - ySpaceOnCurPage = yPageSize - (myTopMsgSpace + SixLinesPerInch); // Allow for continue message and blank line. + ySpaceOnCurPage = yPageSize - (myTopMsgSpace + (yEndMsg == 0 ? SixLinesPerInch: 0 )); // Allow for continue message and blank line. ySpaceOnCurPage -= accountForSmartTemplateHeader; //ySpaceOnCurPage = yPageSize - (myTopMsgSpace + SixLinesPerInch); // Allow for continue message and blank line.