PxPlus User Forum

Main Board => Discussions => Language => Topic started by: Jeffrey Ferreira on August 08, 2019, 04:28:47 PM

Title: *plus\web\request
Post by: Jeffrey Ferreira on August 08, 2019, 04:28:47 PM
Hello,

i've been using *plus\web\request a lot but periodically (once  a day)
i get an error 47 at line 100

recvhdr$=stp(r$(1,o-1),3,$0D$)+$0A$

my first thought is to put an error branch on call and then re-try it...

but has anyone else experienced this error and maybe know a fix

jeff
Title: Re: *plus\web\request
Post by: chrisk on August 08, 2019, 05:25:09 PM
Jeff,

If you want to try putting a fix in *plus/web/request, give this a try:

A few lines ahead of your error, you should see a line where r$ being cleared (just before the while loop).  Try adding o=0 (reset variable o to zero) to that line.  The line will then look like this:

r$=""; o=0

Basically, this ensures o is reset each time the while loop is encountered.  In the normal flow, that is not very critical.  However, if a redirect is encountered and the read record inside the while loop times out, I could see that causing the error 47.

HTH
Title: Re: *plus\web\request
Post by: Jeffrey Ferreira on August 08, 2019, 05:46:25 PM
Chris et al,
thanks
i backed up program.
put change in and saved it.
the request still works ...so that is good....
question:  why did my variables change from lowercase to uppercase in the pxplus program?
should i be concerned
jeff
Title: Re: *plus\web\request
Post by: chrisk on August 08, 2019, 07:43:41 PM
Jeff,

Check out the 'LC' system parameter.  That and some other mixed case logic determines how variables appear when a program is listed.  Generally speaking, I would not worry about it.

Title: Re: *plus\web\request
Post by: Mike King on August 09, 2019, 02:55:22 PM
Two things...