Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Record is out of range
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01173246
Message ID:
01173354
Views:
11
Hi again, Naomi.

>The strange thing, that I don't understand, is that it looks like my command set order
>to 1 is simply ignored.

I know, and this is what's bothering me. I agree with Nigel's solution.
Just use a cursor, and now you don't have to worry about
the pointer being changed. A simple and elegant solution.

>Right before the ENDSCAN command I have
>SELECT comision
> SET ORDER TO 1

Hmmm. In this instance, is 1 a cdx or idx file?
I wonder what would happen if you actually named the file in the
code?

>GOTO m.iRec && Return back to the record
>WAIT WINDOW "Return to the " + TRANSFORM(m.iRec) nowait
>and then replace next 1 ...
>
>
>I added wait window for myself and it's being executed. I do go to the right record
>(originally it seems, like I even was not on the right record,
>
>since iRec and recno() didn't match).

I'd be willing to bet a dime that iRec is lower in value than RECNO().

I'm stating to think that SCAN has it's own idea of where it thinks
the record pointer resides. That is, that dog ain't hunting until
the next iteration of the SCAN loop, or any INSERT, UPDATE, etc. events
change the pointer, yet SCAN refuses to notice the change, even though
you're telling it where it needs to be via GOTO.

>I may add wait window Order right after set order command, but it's very weird...

If you have the time, Naomi, please mess around with the original a bit and
let us know what you find out. I'm starting to sniff a VFP bug, unfortunately.


Regards,

Randall
--
Randall Jouett
Amateur/Ham Radio: AB5NI
I eat spaghetti code out of a bit bucket while sitting at a hash table! Someone
asked me if I needed salt, and I said, "I'm not into encryption." :^)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform