Subject Re: [IBO] Catching actions from TIB_UpdateBar
Author Mario Zimmermann
In BCB syntax:

void TfrmX::UpdateBarBeforeAction (TObject* Sender)
{
TIB_UpdateBar* updBar = dynamic_cast<TIB_UpdateBar*> (Sender);

if ( !updBar )
return;

if ( updBar->FocusedButton == ubCancel )
...
}

HTH,

Mario


--- In IBObjects@y..., Harald Klomann <nibler@t...> wrote:
>
> procedure TfrmX.UpdateBarBeforeAction(Sender: TObject);
> begin
> if (Sender As TIB_UpdateBar).FocusedButton = ubCancel then ...
> end;
>
> Freddy Holst Christensen wrote:
> >
> > Hey
> >
> > I want to catch the different action the user can select by
pressing the buttons
> > in a TIB_UpdateBar, and are landed by BeforeAction event of
TIB_UdateBar.
> >
> > But using dynamic_cast, I haven't succed in finding the correct
syntax.
> >
> > Have anyone tried this, and if so how?
> >
> > I'm using BCB5.
> >
> > Thanks in advance.
> >
> > Regards
> > Freddy