Launching Reporter Problems (OpenInsight 32-bit Specific)
At 11 DEC 2002 05:08:43PM Stephen Sutherland wrote:
Hi!
In a OI application, I have a OIWIN called TE_EXTRACT. This window has a button, with a user-defined CLICK event. The event runs a stored procedure which fills two tables: 1) a table of data calculated from other application tables, and 2) a table of messages (errors/warnings/notes) while calculating that data. The stored procedure then executes a respository item EMMA*OIREPORT*RDLAYOUT*ERROR_REPORT.RPT, which produces a report of the messages.
The odd thing is that Reporter is invisible until TE_EXTRACT is closed. I can wait 10 seconds or 10 minutes, but nothing happens until after I close the TE_EXTRACT window. Then immediately I will get a Print dialog box for the report.
I have tried launching reporter using both REPOSITORY/EXECUTE and UTILITY/RUNWIN. I have launched reporter using /PR, /PV, /ED; /BA; and /QU parameters. I've tried this under OI2.6 and OI4.0.3. While reporter works as expected when it appears, it does not appear until the active window is closed. I've tried minimizing the active window, OI, etc., but reporter is not hiding in the background. Reviewing the Windows task list shows reporter is there, but will not appear until the active window is actually closed.
This is causing problems, ranging from reports not printing to OI locking up.
Can anyone explain why Reporter doesn't just fully launch without regard to the active window event that launched it? Any ideas on how to fix this?
At 11 DEC 2002 05:18PM Richard Hunt wrote:
Stephen,
I think that the "IDLEPROC" property can explain why the stall. Check the remarks section. Maybe???
At 12 DEC 2002 04:09PM Richard Bright wrote:
Doubt if that will make a cracker of a difference.
Problem is that Reporter will only lauch after ALL pending items in the engine queue have been processed. So if you call reporter at a code point in middle of stored proceedure, the Reporter launch process is put in the pending queue till all other code has been processed. This could be a big problem if you have multiple reports or calling reporter prior to a dialog box.
The two possible work-rounds that I know of are
a) re-do the report in OIPI
b) try using the call-back function (documented in Knowledgebase paper).
Richard Bright