Re: I Hate this kind of problem. Please Help



Jeff - thanks for the checking !

Ok - to narrow this down, it's only happening during the FIRST time this is
called.
I remember (with VFP 6) there was some scoping problem with right click
menus -
ie - a right-click 'thing' somehow got top level object, and sometimes could
not see other objects
that might have been exposed at (this) and (thisform) level.

For example, a few times the data environment / data session got switched
out during a right click.
We had no code that did this, it was some side effect.

Is there anything you can do to get to the right data session / data
environment inside of the program thats called with the right click method ?

Regards [Bill]

--
===================
William Sanders / EFG VFP / mySql / MS-SQL
www.efgroup.net/vfpwebhosting
www.terrafox.net www.viasqlserver.net

"Jeff Grippe" <jeff@xxxxxxxxx> wrote in message
news:13r10rnli4qh6b8@xxxxxxxxxxxxxxxxxxxxx
Hi William,

The report does not have a private data session and when I inspect the
data
environment in the report it is blank.

I added a go top to the code after the select and before the report and I
still get the error the first time the report is called. Every other time
through the program there is no problem.

Thanks for the help.
Jeff
"swdev2" <wsanders@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:em$WLCNbIHA.1184@xxxxxxxxxxxxxxxxxxxxxxx
Hey Jeff -

1. are you using the data environment for the report ? I suggest you
don't
!
or if you must, then add in what you need to the DE, on the fly, prior
to
report generation.
2. after the first select line, if you put 'go top' or 'go bottom' , do
you
still get an error ?

--
===================
William Sanders / EFG VFP / mySql / MS-SQL
www.efgroup.net/vfpwebhosting
www.terrafox.net www.viasqlserver.net

"Jeff Grippe" <jeff@xxxxxxxxx> wrote in message
news:13r0u5c75h24c6f@xxxxxxxxxxxxxxxxxxxxx
Hello and thanks in advance for the help.


I have an program which builds a file for the report generator, calls
the
report, and returns.

It is being called from a right click menu of a form.


The code for printing (2 lines)
SELECT Inv_Print
REPORT FORM pickticket to PRINTER NOCONSOLE


The problem is that the first time this PRG is called from the compiled
version I get a variable not found message. The problem does not occcur
on
calls to the PRG after the first one.

Here is what I know about this problem:

1. If I change the REPORT line to include PREVIEW the code works fine

2. If I insert a BROWSE command in front of the REPORT command, it
browses
the INV_PRINT table and then prints fine.

3. If I put the BROWSE after the REPORT command, the error occurs and I
discover that I wasn't actually pointing to the INV_PRINT table.

As I said in the subject, I hate this kind of problem. Does anybody
have
any
potential solutions or debugging suggestions. BTW, if you run the code
in
the debugger, the problem doesn't happen. It was only by sticking the
BROWSE
after the REPORT command that I discovered that it was pointing at the
wrong
table.

The ultimate question is why would it be pointing at the wrong table
when
the SELECT statement is right before the REPORT command.








.



Relevant Pages

  • STS-121 MCC Status Report #05
    ... STATUS REPORT: STS-121-05 ... the first time in more than three years, and for the first time ever that ... crew includes an American, ... feet directly below the station to perform the rendezvous pitch maneuver: ...
    (sci.space.shuttle)
  • Titanic stars Winslet, DiCaprio to reunite for Sam Mendes drama
    ... It will be the first time Mendes has directed his wife, ... the report added. ... The reunion of DiCaprio and Winslet brings together two of the hottest ...
    (rec.arts.movies.current-films)
  • Re: I Hate this kind of problem. Please Help
    ... Ok - to narrow this down, it's only happening during the FIRST time this ... a few times the data environment / data session got switched ... I added a go top to the code after the select and before the report and I ... If I insert a BROWSE command in front of the REPORT command, ...
    (microsoft.public.fox.programmer.exchange)
  • Japan military picks Eurocopter for first time: official
    ... Japan military picks Eurocopter for first time: ... CA - Japan's military will for the first time buy ... U.S. and friendly nation laws prohibit fully ... with our laws this report cannot be provided in ...
    (rec.aviation.military)
  • Japan military picks Eurocopter for first time: official
    ... Japan military picks Eurocopter for first time: ... CA - Japan's military will for the first time buy ... U.S. and friendly nation laws prohibit fully ... with our laws this report cannot be provided in ...
    (soc.culture.japan)