B2020-137 Added a Null reference check to all print to continue processing when it is trying to find a place to break while processing a large table.

This commit is contained in:
John Jenko 2020-10-09 13:27:31 +00:00
parent 8b82722c6b
commit cc06e51dc5

View File

@ -1476,7 +1476,8 @@ namespace Volian.Print.Library
vlnParagraph myPara = FindPageBreak1(yStart, yUpperLimit, yLowerLimit, myList, lastBreak, fullPage, myBottomMsgSpace, RNOContinueOnly, yTop);
float yLocation = GetYLocationFromMyList(myPara, myList);
float spaceOnPage = yUpperLimit + yLocation;
if (myPara.YSize > spaceOnPage && myPara.ChildrenBelow != null && myPara.ChildrenBelow.Count > 0
// B2020-137 added a null reference check - for Wolf Creek SYS GN-120 Attachment B
if (myPara != null && myPara.YSize > spaceOnPage && myPara.ChildrenBelow != null && myPara.ChildrenBelow.Count > 0
&& myPara.ChildrenBelow[0].MyItemInfo.IsTable && spaceOnPage > 0)
{
vlnParagraph tpara = myPara.ChildrenBelow[0] as vlnParagraph;