Just a note on this since I've further worked through this problem..

It seems that replacing the Redirect with the following code: 

      $Server->Transfer('newpage.asp');
      return 1;

...gets around whatever issue that the Redirect has...

So it would seem that Redirect is somewhat broken in Perl 5.8.x?

Also since there seem to be performance benefits to using the Transfer
method (i.e. no roundtrip back to the browser to inform about the
redirect), it seems that I'll be happier with the solution even though
Redirect isn't fixed..  :)

Steven

-----Original Message-----
From: Herbert, Mark [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 08, 2004 12:11 AM
To: '[EMAIL PROTECTED]'
Cc: Steven Manross
Subject: RE: ASP Error with Perl 5.8 on IIS 6.0 


> -----Original Message-----
> From: Steven Manross [mailto:[EMAIL PROTECTED]
> Sent: Thursday, July 08, 2004 2:06 AM
> To: [EMAIL PROTECTED]
> Subject: ASP Error with Perl 5.8 on IIS 6.0 
> 
> 
> Sorry not to continue the thread from a couple weeks ago by "Paul
> O'Russa", but...  I haven't subscribed to THIS activestate list until
> now...

That was back in January, and it was a thread that I started. I updated
recently to 5.8.4.810 and found it had no effect on the problem.

Paul O'Russa found that it worked in IIS6 if he reinstalled perl 5.6.1.
I
rewrote the problem area to avoid redirects, but I still get the error
once
in a while. At least now the user can refresh the browser and then it
works.

Perhaps somebody will think of something if I describe the application.
The
app has two frames: a menu frame and a main frame. The user clicks on
menu
items in one frame, which open asp pages in the main frame. The error
occurs
when the user ends the appilcation. In this case, a javascript function
asks
the user to verify that the app should be terminated, and if so, then it
executes the following:

 window.top.location.href = "form_main_logout.asp";

On the client side, the frames are removed, then this error message is
displayed:

Active Server Pages error 'ASP 0240' 
Script Engine Exception 
/PMV/form_main_logout.asp 
A ScriptEngine threw exception 'C0000005' in
'IActiveScript::SetScriptState()' from
'CActiveScriptEngine::ReuseEngine()'.


The user can refresh the page, and the form_main_logout.asp page
executes
correctly.

My first menu version worked a little different. It did a lot of
redirects.
That did not work at all with perl 5.8 (same error message almost every
time
it did a redirect). Now I have only this one problem when the user logs
out.

If anybody else has this error, what other operations, or app
configurations, can cause it?


> 
> The error WE are getting seems to relate to a value set in the
> Application Pool settings...
> 
> Namely, in the performance Tab, under WebGarden, the "Maximum 
> Number of
> worker processes" seems to control how ofter this error comes up...
> 
> This is by no means a fix (and I am tending to call it a BUG but can't
> say for sure), but I can now go to this page 5 times without 
> seeing the
> error you've referenced (since I set the max to 5)....
> 
>  Active Server Pages error 'ASP 0240' 
>  Script Engine Exception 
>  A ScriptEngine threw exception 'C0000005' in
>  'IActiveScript::SetScriptState()' from 
>  'CActiveScriptEngine::ReuseEngine()'
> 
> ... but then I get the error 5 times when I refresh a page 
> and suddenly,
> voila no more error for 5 more times.
> 
> This is a default IIS 6 install, Perl 5.8.4.810, and a few 
> misc PPMs.  I
> am using Win32::OLE and Win32::Const for use of ADODB.Command and
> ADODB.Connection objects that reference a SQL Server for stored proc
> calls (as well as another 3rd party COM application).
> 
> The page generating this error is the most benign of all the 
> 4 pages in
> this application and it simply looks to see if cookies are 
> enabled, if a
> cookie exists, and then asks the user to login if it doesn't..  or
> redirects them to another page if it does....
> 
> Steven 
> 
> ----CODE----
> <%@ LANGUAGE = PerlScript%>
> <%
>     if ($Request->Cookies("lookimacookie")->{Item} ne "") {
>       $Response->Redirect('myotherpage.asp');
>     } else {
>       $Response->Write("  -- Please login.<BR>\n");
>     }
> %>
> 
> <HTML>
> <BODY>
> 
> <%
>     use Win32::OLE;
>     $bc = Win32::OLE->new("MSWC.BrowserType");
>     if ($bc->{cookies} == 0) {
>       $Response->Write("Your browser doesn't seem to support cookies.
> :(<BR>\n");
>     } else {
> 
>     }
>  %>
> 
> <FORM ACTION="login_verify.asp" METHOD=POST NAME=LOGIN>
>   <TABLE>
>     <TR>
>       <TD>
>         Username:
>       </TD>
>       <TD>
>         <input type=text value="" name=user size=20>
>       </TD>
>     </TR>
>     <TR>
>       <TD>
>         Password:
>       </TD>
>       <TD>
>         <input type=password value="" name=pw size=20>
>       </TD>
>     </TR>
>     <TR>
>       <TD>
>       </TD>
>       <TD>
>         <input type=submit value="Login" name=SUBMIT size=20>
>       </TD>
>     </TR>
>   </TABLE>
> </FORM>
> </BODY>
> </HTML>
> 
> _______________________________________________
> Perl-Win32-Web mailing list
> [EMAIL PROTECTED]
> To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
> 

_______________________________________________
Perl-Win32-Web mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to