LazReport, added option to ignore undefined symbols, from Luiz Americo, issue #21683

git-svn-id: trunk@36720 -
This commit is contained in:
jesus 2012-04-11 05:07:47 +00:00
parent 6eb348b717
commit 34e6e9ce12

View File

@ -79,7 +79,7 @@ type
TfrFrameBorders = set of TfrFrameBorder; TfrFrameBorders = set of TfrFrameBorder;
TfrFrameStyle = (frsSolid,frsDash, frsDot, frsDashDot, frsDashDotDot,frsDouble); TfrFrameStyle = (frsSolid,frsDash, frsDot, frsDashDot, frsDashDotDot,frsDouble);
TfrPageType = (ptReport, ptDialog); TfrPageType = (ptReport, ptDialog);
TfrReportOption = (roIgnoreFieldNotFound); TfrReportOption = (roIgnoreFieldNotFound, roIgnoreSymbolNotFound);
TfrReportOptions = set of TfrReportOption; TfrReportOptions = set of TfrReportOption;
TfrView = class; TfrView = class;
@ -8205,7 +8205,13 @@ begin
aValue:= frParser.Calc(s); aValue:= frParser.Calc(s);
SubValue := ''; SubValue := '';
end end
else raise(EParserError.Create('Undefined symbol: ' + SubValue)); else
begin
if roIgnoreSymbolNotFound in FReportOptions then
aValue := Null
else
raise(EParserError.Create('Undefined symbol: ' + SubValue));
end;
end; end;
end; end;
end; end;