[Openroad-users] Intercepting the OSCAerroronsessiondisconnection.
Thomas, Doug (PSD)
Doug.Thomas at psd.defra.gsi.gov.uk
Thu Dec 20 02:12:46 EST 2007
Hi Bodo,
The "On Error Resume Next" statement stops the offending error message.
Many thanks for your help,
Doug
From: openroad-users-bounces at peerlessit.com
[mailto:openroad-users-bounces at peerlessit.com] On Behalf Of Bodo
Bergmann
Sent: Wednesday, December 19, 2007 2:44 PM
To: International OpenROAD Users
Subject: Re: [Openroad-users] Intercepting the
OSCAerroronsessiondisconnection.
I don't think that the DefineBPM method of the COM class
"OpenROAD.ASOSession" actually writes to the web page.
How could it know that it is used in an ASP and not in a C++ or Excel
client ?
I rather assume that some kind of exception/error is not caught,
so the webserver (IIS) might just catch it and print out all the
available error information.
Have you tried an "On Error Resume Next" statement (e.g. before "Set
objOR = Session("objOR")") ?
Bodo.
Bodo Bergmann
Senior Software Engineer
OpenROAD Worldwide Development
Ingres Corp.
________________________________
From: openroad-users-bounces at peerlessit.com
[mailto:openroad-users-bounces at peerlessit.com] On Behalf Of Thomas, Doug
(PSD)
Sent: Wednesday, December 19, 2007 2:50 PM
To: International OpenROAD Users
Subject: Re: [Openroad-users] Intercepting the OSCA
erroronsessiondisconnection.
Hi Bodo,
I'm using a non-OpenROAD COM Client (ASP/VBScript web pages).
The ASP/VBScript used is:
Set objOR = Session("objOR")
If objOR.i_error_no <> 0 Then
Response.Write( "<BR><DIV>" )
Response.Write( "Error 1.<BR>" )
Response.End
Set objOR = Nothing
Set byrefPDO = Nothing
Set byvalPDO = Nothing
End If
objOR.DefineBPM "WebStats_bpm" - this is line 27 of StatsList.asp
If objOR.i_error_no <> 0 Then
Response.Write( "<BR><DIV>" )
Response.Write( "Error 2.<BR>" )
Response.End
Set objOR = Nothing
Set byrefPDO = Nothing
Set byvalPDO = Nothing
End If
The error message produced in the web browser, when I kill the ASO, is:
OpenROAD.ASOSession error '8004b200'
OSCA fatal error. i_error_no = -101, v_msg_txt =
'uc_context_mgr.RestoreContext: Cannot restore session context.
ContextId 8956 not found.'
/WebStats/StatsList.asp, line 27
I am assuming that the above message is produced automatically. This is
the message I'm trying to intercept.
Thanks,
Doug
From: openroad-users-bounces at peerlessit.com
[mailto:openroad-users-bounces at peerlessit.com] On Behalf Of Bodo
Bergmann
Sent: Wednesday, December 19, 2007 11:47 AM
To: International OpenROAD Users
Subject: Re: [Openroad-users] Intercepting the OSCA error
onsessiondisconnection.
Could you tell where the web browser comes into play?
The OpenROAD Server does not write to a web browser.
So, I assume it's rather the error printing on the client.
Are you using a mode 0 eClient application ?
See the "OpenROAD Server Reference Guide", Chapter "6: ASOLib",
Section "ASOLib User Classes", under "uc_osca (OpenROAD Client)" you
find:
CheckAndHandleError Method (OpenROAD Client)
This error handler method is invoked immediately after making a call to
a GSCP.
Its behavior depends on the type of error (or message) raised by the
OpenROAD Server application.
Error details are contained within the uc_osca instance.
...
User Error
Normally the error text is displayed to the user and GC_I_RESUME is
returned.
If global variable GV_V_OSCA_USERERROR_PROC has been set to a 4GL
procedurename,
that procedure will be called instead of displaying the error text.
(The procedure expects no parameters and must have an integer
returncode;
the returned value will be returned from this CheckAndHandleError
method).
...
Have you set the global variable "GV_V_OSCA_USERERROR_PROC" to the name
of a 4GL procedure,
that does your error printing ?
Hope this helps,
Bodo.
Bodo Bergmann
Senior Software Engineer
OpenROAD Worldwide Development
Ingres Corp.
________________________________
From: openroad-users-bounces at peerlessit.com
[mailto:openroad-users-bounces at peerlessit.com] On Behalf Of Thomas, Doug
(PSD)
Sent: Wednesday, December 19, 2007 12:22 PM
To: openroad-users at sealion.peerlessit.com
Subject: [Openroad-users] Intercepting the OSCA error on
sessiondisconnection.
Dear All,
I'm trying to intercept the OSCA error following the session being
disconnected. The error, which tells the world that we're using
OpenROAD Application Server, appears on the web browser. I'm trying to
stop this happening. This appears to happen at the define BPM stage and
before the error trapping that immediately follows it.
Has anyone got any suggestions?
Thanks,
Doug Thomas
Department for Environment, Food and Rural Affairs (Defra)
This email and any attachments is intended for the named recipient only.
If you have received it in error you have no authority to use, disclose,
store or copy any of its contents and you should destroy it and inform
the sender.
Whilst this email and associated attachments will have been checked
for known viruses whilst within Defra systems we can accept no
responsibility once it has left our systems.
Communications on Defra's computer systems may be monitored and/or
recorded to secure the effective operation of the system and for other
lawful purposes.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.peerlessit.com/pipermail/openroad-users/attachments/20071219/540e8cf1/attachment-0001.html
More information about the Openroad-users
mailing list