Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 10 of 10 total
Thread "Recno := i;" problem
Thu, Nov 8 2007 12:01 AMPermanent Link

"Royke"
This code works on a table 'ConfigTbl', with a single integer field
'ConfigIndex' as index. Typical field values are imply 1, 2, ...

On a table with three records, this piece of code ...
==========
   for i := 1 to ConfigTbl.RecordCount do
   begin
     ConfigTbl.RecNo := i;
     codesite.Send('cfg 1', ConfigTblConfigIndex.AsInteger);
   end;
==========
gives me this codesite output:

cfg 1 = 1
cfg 1 = 2
cfg 1 = 2

But this loop .(run immediately after the first loop)..
==========
     ConfigTbl.First;
     for i := 1 to ConfigTbl.RecordCount do
     begin
       codesite.Send('cfg 2', ConfigTblConfigIndex.AsInteger);
       ConfigTbl.Next;
     end;

==========
.... gives me the correct results:

cfg 2 = 1
cfg 2 = 2
cfg 2 = 3

RJ

Fri, Nov 9 2007 1:20 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< But this loop .(run immediately after the first loop).. >>

I'll check it out and see what I can find.

--
Tim Young
Elevate Software
www.elevatesoft.com

Fri, Nov 9 2007 4:40 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

I can't reproduce this here.  Could you send me the database catalog and
table that you're using ?

I created the table here with a single INTEGER column that was also the
primary key.

--
Tim Young
Elevate Software
www.elevatesoft.com

Sat, Nov 10 2007 1:56 PMPermanent Link

"Royke"
The scenario is a bit more complex. Sample project coming up in your support
email. (First I am still trying to reproduce an earlier problem for you as
well: Locate returns True when done on empty data set. So far no luck. Maybe
it evaporated.)

Roy

"Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote in message
news:CE80C1D2-EB12-4B0E-A078-FC2963FA1300@news.elevatesoft.com...
> Roy,
>
> I can't reproduce this here.  Could you send me the database catalog and
> table that you're using ?
>
> I created the table here with a single INTEGER column that was also the
> primary key.
>
> --
> Tim Young
> Elevate Software
> www.elevatesoft.com
>

Sat, Nov 10 2007 2:17 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< The scenario is a bit more complex. Sample project coming up in your
support email. (First I am still trying to reproduce an earlier problem for
you as well: Locate returns True when done on empty data set. So far no
luck. Maybe it evaporated.) >>

Perhaps it was this issue ?

http://www.elevatesoft.com/scripts/incident.dll?action=viewaddr&category=edb&release=1.06&type=f&incident=2450

--
Tim Young
Elevate Software
www.elevatesoft.com

Sat, Nov 10 2007 3:17 PMPermanent Link

"Royke"
That was it, except that things do also not work ok after 'If you Close and
then Open the table after the first locate, things work as
they should.'. Here I just open the table, call a Locate with a value that
has once been in the table (some earlier session), and I still get True.

I put it in the test project for the RecNo issue. Zipping and emailing that
now.

Roy

"Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote in message
news:FE411BB3-B942-4BC5-BD6F-39A58436BB6D@news.elevatesoft.com...
> Roy,
>
> << The scenario is a bit more complex. Sample project coming up in your
> support email. (First I am still trying to reproduce an earlier problem
> for you as well: Locate returns True when done on empty data set. So far
> no luck. Maybe it evaporated.) >>
>
> Perhaps it was this issue ?
>
> http://www.elevatesoft.com/scripts/incident.dll?action=viewaddr&category=edb&release=1.06&type=f&incident=2450
>
> --
> Tim Young
> Elevate Software
> www.elevatesoft.com
>

Mon, Nov 12 2007 5:45 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< That was it, except that things do also not work ok after 'If you Close
and then Open the table after the first locate, things work as they
should.'. Here I just open the table, call a Locate with a value that has
once been in the table (some earlier session), and I still get True.

I put it in the test project for the RecNo issue. Zipping and emailing that
now. >>

Did you try the locate issue with 1.06 yet ?  It should be fixed.

Also, just so you know - I did not receive the project yet.

--
Tim Young
Elevate Software
www.elevatesoft.com

Wed, Nov 14 2007 7:38 PMPermanent Link

"Royke"

"Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote in message
news:9F51DC11-E2B8-43C1-AF52-F68980FEBEEB@news.elevatesoft.com...
>
> Also, just so you know - I did not receive the project yet.
>
> --
> Tim Young
> Elevate Software
> www.elevatesoft.com

I had sent it to support@elevatedb.com ... It just came back. Resent to
support@elevatesoft.com

I will try 1.06, and let you know.

Roy


Wed, Nov 14 2007 9:56 PMPermanent Link

"Royke"
Tried 1.06. The Locate issue is gone. Thanks. The RecNo issue is still
there.

Roy

"Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote in message
news:9F51DC11-E2B8-43C1-AF52-F68980FEBEEB@news.elevatesoft.com...
> Roy,
>
> << That was it, except that things do also not work ok after 'If you Close
> and then Open the table after the first locate, things work as they
> should.'. Here I just open the table, call a Locate with a value that has
> once been in the table (some earlier session), and I still get True.
>
> I put it in the test project for the RecNo issue. Zipping and emailing
> that now. >>
>
> Did you try the locate issue with 1.06 yet ?  It should be fixed.
>
> Also, just so you know - I did not receive the project yet.
>
> --
> Tim Young
> Elevate Software
> www.elevatesoft.com
>

Thu, Nov 15 2007 6:07 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Roy,

<< Tried 1.06. The Locate issue is gone. Thanks. The RecNo issue is still
there. >>

Okay, I found it with your project.  The issue is the active range due to
the master-detail link.  As a workaround, you'll have to simply use the
MoveBy() method for now.

--
Tim Young
Elevate Software
www.elevatesoft.com

Image