Portal Development Company Issue

Hi

I’m creating a portal through Dynamics ax 4. In my potal I have a list of companies displayed that the current user have access to. Now, when the user selects one of the companies in the list, I want to change to the selected company on a portal wide scope, so that if I navigate to different pages, the newly selected company’s data and everything else needs to be worked on.

I’ve tested the following functions: datasource.company(some comp id), and changecompany(some comp id); But the company change is only temporary to that method/block of code/webform.

Can someone please tell me if a portal wide company change is at all possible, and if so how to do this. It is done in the normal Dynamics ax 4, but that does not seem to apply to web development. [:S]

Thank you very much for any replies.

Jannie Blignaut