Hi Jorge,
Here is the situation I first experienced this problem, and then I saw similar problem referenced in other cases:
We have a main application, which is called JobControl. This application has ability to execute other applications. This application has a form called JobViewer this gives you a list of jobs to run. They are shown in a grid.
One of the step was my Special application. This application has main program like this:
do case
case tcSpecialCode = ...
=myUDF(Parm1,Parm2)
case tcSpecialCode = ...
=myUdf2(...)
endcase
e.g. this application was developed to non-standard situations...
In one of the program there was creation of a cursor and then report form command. I got the same error message and spent about day or more debugging it before I found this bug. I solved it by using session class for this application, which, BTW, was a good thing anyway. I'm also aware of it, so I can code more carefully...
>Could you expand on this, I'm pretty sure I print reports from forms with grids all the time, usually by clicking a button, I suppose the grid looses focus then?.
>
>I've had problems like the one mentioned, but usually, depending on the situation, it get's solved by:
>
>- Selecting the cursor before calling the report
>- Having the line "This.InitialSelectedAlias = CURSORNAME" in the report DE's BeforeOpenTables (even though I'm using a generated cursor)
>- Doing a go top in the cursor (I had done some processing that left the cursor at eof)
If it's not broken, fix it until it is.
My Blog