Overloading methods of ancestor component

Hi,

I have created a class that is derived from a ActiveX control. I imported
the Microsoft Comm Control OCX into Builder 4. I then derived a class from
it. Now in the past I have used this derived class to write data to the
serial ports, but I have never tried receiving data from the serial port
with this class. I have created a method that I assign to the classes OnComm
event to utilize, but this method is never fired. Am I wrong in my
understanding of how methods and events are derived from other components?

Here is some sample code illustrating exactly what I am doing:

// TMSComm is an imported OCX

class UniPage_Comm : public TMSComm
{
    public:
        void __fastcall UniPage_OnComm(TObject *Sender);
        UniPage_Comm():TMSComm()
            {
                this->OnComm=UniPage_OnComm;
            }

    // private members and other public members are in here

Quote
};

// this method is never called, even though I explicitly declare it as the
event handler for the class in the constructor
void __fastcall UniPage_Comm::UniPage_OnComm(TObject *Sender)
{
    TMSComm::OnComm(Sender);
    switch(this->CommEvent)
        // handle comm events here

Quote
}

Again, I have had no trouble with using this derivation from the TMSComm
control when writing to the ports, but I have been very confused trying to
get it working with the events from the derived control.

I would greatly appreciate if someone could set me straight on this.

Thank you,
Walter Goulet
wgou...@bellsouth.net