Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Inheriting Events

edited February 2002 in General
Hello there,

I have a not so small problem with my report-builder. The situation is as
follows: I have an ancestor-form, which contains a report. On this form I
put some code in the OnPreviewWindowCreate-event (to maximize the
preview-window). I derive a new form from this one (so it inherits the
properties), but previewing the second report, it shows in "normal" small
size. Stepping through the code I found out that the OnPreviewWindowCreate
in the ancestor-form isn't called. And I cannot "redefine" the method in the
second report, because the form is only created at run-time, I can't change
the properties at design-time (i.e. Form2:=TAncestorForm.Create(Self);).

I tried assigning a procedure to the OnPreviewWindowCreate-property, but
this one isn't called either (i.e. Form2.OnPreviewWindowCreate :=
SomeResource.MyProcedure). What can I do? Any ideas?

Regards,

Marc

Comments

This discussion has been closed.