Subject RE: [IBO] IB_Query OnCalculate Not firing?
Author Kevin Stanton
Greetings! And Problem found!

In this particular query, at one point I am manipulating/clearing the SQL
property.

It appears that the CalculatedFields property is getting cleared somewhere
along the way. This never used to happen in V3.6x.
I put in a showmessage on the before open to show the count of calc fields -
there are 3 at design-time, zero at runtime.
I then added a button to the form and:

Showmessage('qryDtlOH2BeforeOpen - CalculatedFields count = ' +
IntToStr(qryDtlOH2.CalculatedFields.Count));
If qryDtlOH2.CalculatedFields.Count = 0 then
begin
qryDtlOH2.Close;
with qryDtlOH2.CalculatedFields do
begin
Add('AVAILPCS DOUBLE PRECISION');
Add('AVAILFTG DOUBLE PRECISION');
Add('COSTPM DOUBLE PRECISION');
end;
qryDtlOH2.Open;
end;


After the above code executed, I got my calculated fields in my grid.

Could this be made to function as 3.6x??

Best regards and HAPPY NEW YEAR!

Kevin

-----Original Message-----
From: Geoff Worboys [mailto:geoff@...]
Sent: Saturday, December 29, 2001 4:24 PM
To: Kevin Stanton
Subject: Re: [IBO] IB_Query OnCalculate Not firing?


> I am just trying to migrate my app to D6 and IBO V4.2.Fn.

Trying to change two such major aspects at the same time can often be
painful :-)


> I have a grid that has two fields that are not showing and are
> defined in GridLinks.

> Relatedly, I have an IB_Query that the OnCalculateField does not
> seem to be firing.

I cannot think of any reason why you will be having problems in these
areas. The best I can suggest to begin with is to try and create a
new demo application and see if the problems persist. That way you
will know if it is a generic problem or something peculiar to the
main application.

If the problems exist in the demo then you will have something to send
to myself or Jason. I am still waiting on my Delphi6 upgrade, so
cannot be of immediate help in that regard. Since I am not aware of
any such bugs, you may be well advised to check your paths for old
version files - if you still have D5 and/or IBO3 installed make sure
you have all the search path and temporary path details configured
correctly in your application.

If the problems dont exist in the demo then you can start comparing
properties etc to see if you can discover the differences and so
possible problems.


--
Geoff Worboys
Telesis Computing


Yahoo! Groups Sponsor
ADVERTISEMENT





___________________________________________________________________________
IB Objects - direct, complete, custom connectivity to Firebird or
InterBase
without the need for BDE, ODBC or any other layer.

___________________________________________________________________________
http://www.ibobjects.com - your IBO community resource for Tech Info
papers,
keyword-searchable FAQ, community code contributions and more !

Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.



[Non-text portions of this message have been removed]