B2021-142 fixed invalid & character in table text when printing the table.

This commit is contained in:
John Jenko 2021-12-03 17:06:03 +00:00
parent 6828b5cca3
commit 617362fdb0

View File

@ -1061,6 +1061,7 @@ namespace Volian.Controls.Library
try
{
str = AdjustHeightAndWidthForDPI(str);
str = Regex.Replace(str, "&(?![a-z])", "&"); //B2021-142 fix &'s in text screen - so they are considered text instead of xml
using (StringReader sr = new StringReader(str))
{
ReadXml(sr);
@ -1084,6 +1085,7 @@ namespace Volian.Controls.Library
DPIscreen = (int)gr.DpiX;
}
XmlDocument xd = new XmlDocument();
str = Regex.Replace(str, "&(?![a-z])", "&"); //B2021-142 fix &'s in text screen - so they are considered text instead of xml
xd.LoadXml(str);
XmlNode xn = xd.SelectSingleNode("//DPI");
if (xn != null && xn.InnerText != DPIscreen.ToString())