LazReport: check variable existence before trying to show it's composition (variables editor form), from Michel Tournay, issue #26281

git-svn-id: trunk@45370 -
This commit is contained in:
jesus 2014-06-06 06:24:49 +00:00
parent a13f3e80da
commit 8ca217203a

View File

@ -286,9 +286,14 @@ begin
end;
procedure TfrEvForm.ShowVarValue(Value: String);
var
frValue: TfrValue;
begin
if Value='' then Exit;
with Doc.Values.FindVariable(Value) do
frValue := Doc.Values.FindVariable(Value);
if frValue=nil then
raise EParserError.Create('Undefined symbol: ' + Value);
with frValue do
case Typ of
vtNotAssigned:
SetValTo(CurDataSet + '.' + sNotAssigned);