Analyzing Employee Distribution with Notes View Container
In this workshop the student will practice using the actions (Total， Min， Max， Average and Count） of the Notes View container to analyze employee information. Student will walk through the creation of a composite application and demonstrate how the actions work in the Notes view container. The conceptual use case for this application is: the data of the selected entries in the Notes view container will be calculated and transferred to the Symphony Spreadsheet Container. The Symphony Spreadsheet Container then shows the calculated data as charts. When changing selections in Notes View container, the charts in Symphony Spreadsheet Container will reflect the changes dynamically. In essence the selection in the Notes view container is the data-set used to populate the charts in Symphony. This pattern can be useful when only a subset of records in a view want to be visualized with a chart.
1. Install Lotus Notes 8.5.1 GM (or beta) build, make sure Composite Application Editor and Lotus Symphony are selected during installation.
2. Copy the statics.ods and landmark_SymphonyContainer.xml file to c:\
3. Copy the Employees.nsf to C:\Program Files\IBM\Lotus\Notes\Data
Step 1 – Create a Notes Composite Application
1. Start Notes client
2. Select File | Application | New… to open the New Application dialog
3. Type the name of the composite application (e.g., MyCA) in the Title field
File name will be automatically generated in File name field
4. Choose the template of the composite application as -Blank Composite Application-
5. Click [OK] button.
Now the CA will be created and opened in Lotus Notes client automatically.
Step 2 – Assemble the Composite Application
1. Select “Actions | Edit Application” to open the application in the Composite Application Editor (CAE).
2. From the CAE Palette on the right sidebar, drag/drop the “Notes View Container” and “Symphony Spreadsheet Container” onto the empty canvas. Now the page will show like this:
Step 3 – Configure Notes View Container
1. In the left navigator, right click on Notes View Container and select “Edit Component Properties”
2. In the Edit Component Properties screen, change the component name to “Employees” under the Component Settings tab.
3. Click the Browser button, in the “Locate Object” dialog:
a. Choose “View” in the “Kind of object” dropdown list
b. Click the File icon to choose the “Employees.nsf” under C:\Program Files\IBM\Lotus\Notes\Data
c. Choose “All Employees” in the “View” dropdown list
4. Click [OK] button to return to the”Edit component properties” dialog.
5. In the Selection Output tab, add the properties as the picture below, notice we use all of the different functions for this article. You can get a quick help for each action on the same dialog near the bottom. These actions can also be populated from the main CAE screen using the toolbar functions of the Notes View container.
6. Select “name” in the “sort output by” dropdown list, this identifies the order in which the values are published out of this view component.
7. Click [OK] button to exit the “edit component properties” dialog
Step 4 – Configure Symphony Spreadsheet Container
1. In the CAE left navigator, Right click “Symphony Spreadsheet Container”, select “edit component properties”:
2. In the coming dialog, switch to the “Component Settings” Tab:
a. Change the component title to “Statics Result”
b. Change the value of “initial File” to “c:\static.ods”
3. Switch to Landmarks tab, add the following landmarks by importing landmark configuration:
a. Click [Import] button
b. Select the c:\landmark_SymphonyContainer.xml, click [Open] button
c. The landmark configurations will be as in the snapshot below
* It is important to note we complete both the Content Complete and Data Change events for each tab in the spreadsheet. This is so data will be sent to each tab when it has focus.
4. Click OK button to exit the “edit component properties” dialog.
Step 5 – Create the wires between Notes View Container and Symphony Spreadsheet Container
1. In the CAE left navigator, right click the “Employees” component, select Wiring
2. In the wiring UI, create the wires as the picture below. The pattern for our wires is:
XXX -> set XXX
3. Click [Apply] button to save wires.
Step 6 – Exit Composite Application Editor
1. Select File->Save and Close
2. Select YES to exit CAE.
Our application is ready for use!
Step 7 – Run the Composite Application
1. Select multiple Entries in the Employees View, the name, age, division and country info will be transferred to the “Employees” worksheet of “Symphony Spreadsheet Container”. The page will show like this:
2. In “Symphony Spreadsheet Container”, switch to the “age” worksheet, the page will show like this:
3. In “Symphony Spreadsheet Container”, switch to the “Division” worksheet, the page will show like this:
4. In “Symphony Spreadsheet Container”, switch to the “Division” worksheet, the page will show like this:
After walking through the scenario described in the tutorial, student should understand the following items:
1. How to create a Notes Composite Application
2. How to Assemble a CA in CAE
3. The usage of custom actions(Total, Min, Max, Average and Count) of Notes View Container
4. How to receive properties in Symphony Spreadsheet Container
The tutorial you learned here can help you use Notes View Container to solve other challenges.