Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error Record is out of Range
Message
 
 
To
22/05/2021 17:11:40
General information
Forum:
Visual FoxPro
Category:
Troubleshooting
Miscellaneous
Thread ID:
01680680
Message ID:
01680684
Views:
35
>>I was looking through an error log of one of the customers and I see, at least, a few times a year the error "Record is out of range.". The error log writes that the the last level that the function ASTACKINFO(aStackArray) got is the Start() method of the application object. I have seen this error before and always the ASTACKINFO() points to the Start() method (which is the very first method fired by the application - after user logs in). And I always thought that this error actually happens in the Start() method. And I could not see how.
>>
>>Today I looked at a couple of screen shots created when the error occurred. And the screen shot show one of the form/windows of the application. Yet, the ASTACKINFO() has nothing about this form.
>>So, my question. How could it happen that the error actually happens in one of the forms of the application but the error log (created with ASTACKINFO) only shows the Start() method?
>
>Without diving into your details, that error is almost always caused by a corrupt index. You could approach this by looking for places where you use an indexed table, cursor etc.
>
>There was "one weird error" documented some time ago which could come up when:
>
>- a form is instantiated
>- the form contains a combobox
>- the combobox's data source is a table or cursor
>- the data source either is not present or not populated (?) at the time the combobox is instantiated
>
>I can't remember if the error raised was "Record out of range" or if it was something like "File does not exist" or "Alias is not found" - maybe someone else recalls the details (?) The takeaway is you need to ensure data sources for controls are present before trying to instantiate them.
>
>UPDATE: is this customer the one where you're having the other problems?

First, thank you for your input.
No, this is not the customer that has problems with the PC disconnecting from the server.
My question was more to do with how come the error log (created by the ASTACKINFO() does not show the form where the error occurs.
As far as the error itself, now that I know that the error is created in this form and checking the images, I suspect that the error is caused by the grid. Tamar helped me resolved a problem, some months ago, that was also caused by the grid and the report. Her exact message is:
"If the form you're doing this from has a grid, make sure to keep the grid from having focus when you run the report. If the grid gets focus, it changes the workarea to its underlying table."
So far, I cannot duplicate the problem on my PC.

But, again, the question is more to do with the ASTACKINFO() that the error itself.

Again, thank you.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Reply
Map
View

Click here to load this message in the networking platform