Step 3 Create Session Management 2 WAM

LANSA WAM

Step 3. Create Session Management 2 WAM

WAM080 - Session Management

In this step you will create a second WAM and enable session management in both WAMs so that they share a common Session GroupName. This makes both WAMs part of the same session. The new WAM will contain the WebRoutines showsave and showemp and the session invalid event handling routine.

1.  Create WAM iiiSessionMng2 by copying WAM iiiSessionMng. Perform the copy step as follows:

a.  Select the WAM iiiSessionMng on the Favorites / Last Opened tab and Copy it using the context menu.

b.  In the Active Designs dialog, select only SHOWEMP and SHOWSAVE.

2.  Delete the WebRoutines INIT and SEARCH from the new WAM.

3.  Change four transfer commands to specify the WAM name and WebRoutine name, for example:

Transfer Toroutine(#iiiSessionMng.search)

4.  Press F7 to display the WAM properties on the Details tab. Change the Session GroupName to IIIGROUP.

     Set the Session Timeout value to 300.

5.  Compile WAM iiiSessionMng2.

6.  Open the showsave WebRoutine in the Design view and give the Return push button an on_click_wamname property of iiiSessionMng.

7.  Open the showemp WebRoutine in the Design view and give the Return to Search push button an on_click_wamname property of iiiSessionMng.

8.  Save your changes.

9.  If necessary open WAM iiiSessionMng in the editor.

10. Open the search WebRoutine in the Design view. Make the following changes:

Push Button

Property

Value

Show Saved List

on_click_wamname iiiSessionMng2

Show Employee Details

on_click_wamname iiiSessionMng

 

11 Save your changes.

12.  Press F7 to display the WAM properties on the Details tab. Change the Session GroupName to IIIGROUP.

     Ensure the Session Timeout value to 300.

13. Compile WAM iiiSessionMng.