Dynamic rich media component for ASP.Net Flash, Video and Audio controls for C# and VB.Net

Speaking with Persistent State Objects

The ActionSpeak Persistent Objects allow Flash Movies to remember data when users reload, or return to the web-page. To access them, you must Install ActionSpeak™ into your Flash Movie.

The ViewState

Persistence is now handled in Flash with the ActionSpeak ViewState.  The ViewState is a string which you can set and get at any time  It remains the same even after the page has been submitted or refreshed.

Saving a simple Viewstate.

The following code will save the current frame of the Flash Movie into the ViewState.

[ActionScript]

Restoring the Flash Movie using the ViewState.

The following code will retrieve the ViewState value after each page post-back. It will then return the Flash movie to its previous position.

[ActionScript]

So save more complex data into the viewstate - we suggest that you serialize your variables into delimited strings or XML, then save them to the ViewState.

 

The SessionState

Persistent state is similar to ViewState except is available on all page of a website ­and will be restored on return visits.  The SessionState exploits the browser's cookie mechanism.

Data is saved and retrieved in key-value pairs for versatility.

[ActionScript]