The technique Tamas Hoznek is referring to is described in this blog - Data caching in Personas scripts.
Essentially you use "Calculate in JavaScript" actions to store data "globally", in other words in the browser window object. Those values persist between scripts and even between transactions. The disappear when the browser page is refreshed. I think this is what you are looking for.
Be aware that this technique does still work in Personas 3 when run in a browser. However, Personas 3 is also supported in the native Windows and Java versions of SAPgui, and there this technique doesn't work. There is no "window" JavaScript object in the Windows SAPgui. There is a new mechanism supported in Personas 3 for storing data more persistently, so if you are building flavours that you want to be usable in the GUIs as well as in a browser, you'll need to plan to convert to this standard technique when you upgrade to Personas 3.
Steve.