- Jay Pillai
- PowerBuilder
- Thursday, 6 May 2021 11:19 AM UTC
Hi
I know this question was asked before but the solution provided for some reason did not work for me.
My issue is with the cache when I call a REST service using Msxml2.XMLHTTP.6.0. I am Using PB 2017 R3.
I use GET,POST and PUT requests. The GET Userid and password are different to POST and PUT (POST and PUT have the same).
The first time I do a GET, with the Userid and password it works. Now I have to do a POST
or a PUT, the userid and password changes here and the request fails because it takes the userid and password from GET. After closing the Application, the other way around if I do a PUT first it works and then doing a GET fails for the same reason.
I tried all these Header options but to no avail.
oleHTTP.setRequestHeader("Cache-Control", "no-cache, no-store, private, max-age=0")
oleHTTP.setRequestHeader("Pragma", "no-cache");
oleHTTP.setRequestHeader("Expires", "Tue, 01 Jan 1900 1:00:00 GMT")
oleHTTP.setRequestHeader("If-None-Match", "??Dummy??" + string(li_random2) );
Thank you
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.