I have an application with a screen where the user selects a number of options and then clicks a button which refreshes the page but with the content updated to reflect their choices; basically it filters search results.

The problem is that when I try to save the selections to a cookie, the cookie is created but when the page refreshes it does not read the current copy but seems to read the previous version of it.
So if the user selects option A and B, then clicks the button, the page refreshes with no changes made; if they then select options A, B and C and filter, the page will display as if option A and B only had been selected. They would then have to refresh to get option C selected as well.

Does anyone have any idea why this would be happening?
Hi Robert,

I'm not really sure I'm following your problem. Are you using the HTTPRequestHandler Extension's cookie methods? By the way, why are you using cookies and do not use local variables instead? If you could post a simple example maybe it could be easier to understand your problem.

Tiago Simões
Hello Tiago,

Got it sorted. The reason for using the cookies is that the application is made up of several eSpaces and the variables were getting cleared between pages. We're not upgrading to Outsystems Platform 4.1, which I believe allows session to persist between eSpaces(?), for another couple of months so cookies is the solution for now.
Managed to workaround the problem with a combination of query strings and cookies in the end, but thanks anyway.