Q-RunTime Creation of buttons and event handlers

   I need advice as to how to go about creating an event handler for two
buttons I've created at run-time.  On my forms.create procedure, I create
the two buttons, assign their properties, (top, left, visible, etc).  
These two buttons have their parent property point to a TPanel component,
also created at run-time. The TPanel.canvas property is used for a print
preview screen and I want to use the two buttons to page through the
preview screens.  I suspect that the problem I am having is one of scope,
where the event handler does not detect the 'instance' of the button
which was pressed.
    Do I need to re-assign the parent property to that of the Form, so
that the event handlers will page correctly? Do I need to create the
buttons at design-time so I can tie the event handler correctly?   I
thought the create format , i.e. buttoninc := tbutton.create(self),
created the identification need to properly reference the current
instance of a created component.  I looked at the object browser and saw
no evidence of messages being created by actuating these buttons, even
though they responded to depressions (clicks).
    On another vein, I used Winexec to run local programs from within my
app, i.e. Notepad and Write, as tools for my app.  I have tried all of
the ShowWindow commands and still have not been able to resolve this
problem.  The Winexec execute works properly; however, as soon as I click
on any part of the screen outside of the tool window, the tool app
minimizes and must be accessed via 'Switch To'.  I would like to create a
'MDI child window' for the tool application, for I want to be able to use
the tool app to copy, paste, and edit from within the tool.  Is this not
what multitasking was supposed to be about?  Does anyone have any

Please e-mail any comments to d...@mailgw.sanders.lockheed.com

    Dan Roy