You may use several applications in the course of a single work activity. Some may be Notes applications which you might organize through icons on your Notes Workspace. Others might be web applications which you might organize through bookmarks in your browser.
This recipe shows you how to create a composite application that allows you to place these applications together within a single tabbed view. Instead of having to change from context to context you can work with all of them from a single tabbed environment.
What you need
(1) You will need the URLs to any web applications you want to display. Browse to the web application and when you are at the screen you want, cut and paste the text in link window. This will usually begin with "http://". In the "Hannover Central" example we used the URL to the Composite Application blog "http://www-03.ibm.com/developerworks/blogs/page/CompApps".
Adding a Notes Application
To add a Notes application, we first add a component pointing to the view we are interested in to the component palette. Then we drop that view onto the work surface.
The palette is contained on a pop-out bar on the right hand side of the CAE. You can pop it out briefly by clicking the tab on the right hand side. If you want to work with it for an extended time, you can "pin" it in place by clicking on the little menu icon in the top right of the window (on the title bar next to "Component Palette") and selecting "Set Palette Pin". Repeating the process and selecting "Unset Palette Pin" will return it's behavior to normal.
You may want to create a category to organize the components you create for this application. You can right click on the palette and select Add Category.
1. Right click on the Component Palette and select Add Components -> Add NSF Component. Click on the Browse Button. From here select "View" from the top drop down. Then pick or navigate to the database application you want to include from the middle drop down. Finally select the view you want to display from the bottom drop down. Click OK when you have all of these.
2. Enter in a sensible name and description for the component. In most circumstances you want to add &HideNavigator to the end of the Notes URL. This suppresses the display of any navigator associated with the view. You can experiment with this by later changing the value through the Advanced Component Properties for this component.
4. You can now drag and drop the component from the palette onto the work surface. You can arrange it any way you like, but for this recipe you might find that dropping each component on top of the previous one to create a tabbed view is best.
Adding a Web Application
To add a Web application, we add a Managed Browser component. Then we set an advanced property to tell it what URL to bring up initially.
If you do not already have the Managed Browser component in your palette, it is easy to add. Right click the Component Palette and select Add Components -> Add Locally Installed Components. Check off the check box next to Managed Browser.
1. Drag and drop a managed browser component onto your work surface. As mentioned under Notes applications, you can put it anywhere you like, but you might find dropping it straight on top for a folder view to be the most useful.
2. In the component navigator on the left hand side of your screen, right click the Managed Browser component you just added and select Edit Component Properties.
3. On the Edit Component Properties dialog box select Advanced.
4. In the Advanced Component Properties dialog box Click "add". In the field enter in initialURL. (Note: this is case sensitive.)
5. Click on the Edit button and in the other field enter in the URL (1) you noted above.
6. Click OK to leave the Advanced Component Properties dialog box and OK again to leave the Component Properties dialog box.
How it Works
When the application is run, each Notes View is brought up, just the same as it would be from the Notes application. Only in this case we use the power of Composite Apps to display it within a tabbed environment. Similarly, instead of launching a web page in a standalone browser, or in a top level tab in Notes, we have it within a tabbed composite application view.
For this recipe there is no integration between the different applications shown. There are additional ways we can start to make these applications interact in further recipes.