Dynamic child band creation
Hi all,
I've an application which uses some dynamic tables (two dimensions array of string not DB).
I want to report theses tables so I use two children to add child band:
But I get it overlapped.
Any suggestion please.
Regards.
I've an application which uses some dynamic tables (two dimensions array of string not DB).
I want to report theses tables so I use two children to add child band:
  Band := TfrxReportSummary.Create(frp_Main.Pages[1]);
  Band.CreateUniqueName;
      if Assigned(Child1) then
      begin
        Child2 := TfrxChild.Create(frp_Main.Pages[1]);
        Child1.Child := Child2;
      end
      else
      begin
        Child2 := TfrxChild.Create(frp_Main.Pages[1]);
        Band.Child := Child2;
      end;
      Child2.CreateUniqueName;
      DrawTable(Child2, ...);
But I get it overlapped.
Any suggestion please.
Regards.
Comments
Like Child2.top := child1.top +child1.height +1
Also, to understand what's going on, after you created all objects and prepared the report, export it into a .fr3 file, open the result again with the editor and check how the objects are placed, it will help you to visualise where the objects create at runtime were place and the source of your problem.
If you want to dig further, then edit the objects in the editor (if possible, can be tricky without the right datasets) until you get the right output, and then try to mimic the final correct layout from your code by setting all properties missing.
Thank you very much for your reply.
I've fixed my problem.
Best regards.