mark_h
14th November 2006, 13:42
Just a heads up on something you might run into with SP20. I have a simple litte function server that takes input from a file and runs the reports to temporary file(using ASCIT append to file). Under SP20 it would work the first time, but then fail from then on - user would have to exit and re-enter the program. A basic summary of the program is like this:
(1) Open file
(2) Create temp file - set spool.fileout to temp file
(3) Read record
(4) Run report session appending to temp file
(5) Get next record until read file empty
(6) Close report session
(7) Download file to PC.
What I found was that the second time the user ran my session the variable spool.fileout was set to a new temp file, BUT the report session still had spool.fileout set to the original temp file.
Just something to keep in mind. I have since change my function server script to only use the first temp file name. Should work from here on out. I do not know why these global variables seem to stop working(had the same problem with SP19 and spool.pr.copies) or maybe I am not understanding something.
(1) Open file
(2) Create temp file - set spool.fileout to temp file
(3) Read record
(4) Run report session appending to temp file
(5) Get next record until read file empty
(6) Close report session
(7) Download file to PC.
What I found was that the second time the user ran my session the variable spool.fileout was set to a new temp file, BUT the report session still had spool.fileout set to the original temp file.
Just something to keep in mind. I have since change my function server script to only use the first temp file name. Should work from here on out. I do not know why these global variables seem to stop working(had the same problem with SP19 and spool.pr.copies) or maybe I am not understanding something.