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

Customize my TppOutlineViewer (custom Outline)

edited August 2003 in General
Hi !

I created an Outline in my preview form (using TppOutlineViewer.Create(nil)
and so on) and I want to customize the TppOutlineViewer.PopupMenu. Is there
a way to do that ? I want to add Glyphs to "Hide/Show Outline", "Expand
Outline", "Collapse Outline" and I also want to change the captions.

I also want to change the event contained in "Hide/Show Outline". I want to
add some instructions to this event...

How I can do all of this ?

Thanks a lot !

Alex.

Comments

  • edited August 2003
    Hi Alex,

    Although it should have been, the PopupMenu for the OutlineViewer was not
    coded so that it could be customized easily. The only way to customize it
    right now would be to change some of the ReportBuilder source. I realize
    you are still testing our product and most of this information is useless
    but if you do decide to buy, you will want to look at replacing the
    TppPreview.BeforePreview routine and the TppOutlineViewer.EnableOutline
    routine in your own descendents so that you can access the properties of the
    PopupMenu and the click events associated with it.

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited August 2003
    Hi again !

    Is there a way (easy one) to not have a PopupMenu for the OutlineViewer ?

    Thanks !

  • edited August 2003
    Hi Alex,

    In the example I sent you adding an outline to a TppViewer, add the
    following line of code to the bottom of the TForm1.CreateOutline event...

    FOutlineViewer.PopupMenu := nil;

    This will disable the popup menu for you. If you wish to disable it in the
    original Report Previewer, the process will be a little more difficult. You
    will need to create a TppPreview descendent and override the
    TppPreview.BeforePreview routine without calling the EnableOutlinePopup
    procedure.

    --
    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.