Subject Re: [IBO] Re: IB_ActionUpdate.pas
Author Jason Wharton
Thanks for these fixes. They will be in the next sub-release.

Regards,
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com


----- Original Message -----
From: "Sergey Kanovka" <sergey.kanovka@...>
To: <IBObjects@yahoogroups.com>
Sent: Friday, May 11, 2001 12:42 PM
Subject: [IBO] Re: IB_ActionUpdate.pas


> --- In IBObjects@y..., "Serge" <sergey.kanovka@s...> wrote:
> > I found errors in TIB_ActionPost.StateChanged and
TIB_ActionCancel.StateChanged that prevent Enabled property from changing
properly:
> >
> > Instead of
> >
> > Enabled := Assigned( ADataSource ) and
> > Assigned( ADataSource.DataSet ) and
> > ( ADataSource.Dataset.NeedToPost ) and
> > ( ADataSource.Dataset.State = dssSearch );
> >
> > is should probably be
> >
> > Enabled := Assigned( ADataSource ) and
> > Assigned( ADataSource.DataSet ) and
> > ( ( ADataSource.Dataset.NeedToPost ) or
> > ( ADataSource.Dataset.State = dssSearch ) );
> >
> > --
> > Serge
>
>
> Some more things. TIB_ActionPost and TIB_ActionCancel do not work when
dataset is in dssSearch mode. Suggested changes:
>
> procedure TIB_ActionPost.ExecuteTarget(Target: TObject);
> begin
> // if Assigned(DataSource) then
> // with DataSource do
> // begin
> // if Assigned(Dataset) then
> // with Dataset do
> // if NeedToPost then
> // Post;
> // end;
>
> if Assigned( DataSource ) and Assigned( DataSource.Dataset )
> then DataSource.Dataset.Post;
>
> end;
>
> procedure TIB_ActionCancel.ExecuteTarget(Target: TObject);
> begin
> // if Assigned(DataSource) then
> // with DataSource do
> // begin
> // if Assigned(Dataset) then
> // with Dataset do
> // if NeedToPost then
> // Cancel;
> // end;
>
> if Assigned( DataSource ) and Assigned( DataSource.Dataset )
> then with DataSource.Dataset do
> if State = dssSearch then
> begin
> ClearSearch;
> Open;
> end else Cancel;
> end;
>
> --
> Serge
>
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>