Browse Source

* Do not continue if visible=false for elements

git-svn-id: trunk@37676 -
michael 7 years ago
parent
commit
5d5e38ec84
1 changed files with 6 additions and 0 deletions
  1. 6 0
      packages/fcl-report/src/fpreport.pp

+ 6 - 0
packages/fcl-report/src/fpreport.pp

@@ -4440,6 +4440,8 @@ Var
 
 
 begin
 begin
   Result:=Inherited PrepareObject(aRTParent);
   Result:=Inherited PrepareObject(aRTParent);
+  if Result=Nil then
+    exit;
   m:=TFPReportCustomMemo(Result);
   m:=TFPReportCustomMemo(Result);
   if moDisableExpressions in m.Options then
   if moDisableExpressions in m.Options then
     Exit; // nothing further to do
     Exit; // nothing further to do
@@ -4754,6 +4756,8 @@ Var
 
 
 begin
 begin
   Result:=inherited PrepareObject(aRTParent);
   Result:=inherited PrepareObject(aRTParent);
+  if Result=Nil then
+    exit;
   img := TFPReportCustomImage(Result);
   img := TFPReportCustomImage(Result);
   B:=artParent as TFPReportCustomBand;
   B:=artParent as TFPReportCustomBand;
   if (img.FieldName <> '') and Assigned(B.GetData) then
   if (img.FieldName <> '') and Assigned(B.GetData) then
@@ -4925,6 +4929,8 @@ Var
 
 
 begin
 begin
   Result:=inherited PrepareObject(aRTParent);
   Result:=inherited PrepareObject(aRTParent);
+  if Result=Nil then
+    exit;
   C:=TFPReportCustomCheckbox(Result);
   C:=TFPReportCustomCheckbox(Result);
   s:=ExpandMacro(C.Expression, True);
   s:=ExpandMacro(C.Expression, True);
   C.FTestResult := StrToBoolDef(s, False);
   C.FTestResult := StrToBoolDef(s, False);