Creating Shared Actions

Actions were new to Release 4 and provided a way to create programmable buttons that consistently stayed at the top of the form or view in which they were placed. Unfortunately, there was no way to create an action and reuse it in multiple forms and views until Release 5. In R5, actions became shareable throughout the design of a database. With the advent of Domino 6, actions are now part of the Shared Code section in the Design pane IDE. You can place actions in forms, subforms, pages, and views. What's more, you can code an action once and then reuse it repeatedly.

To create a new action, select Actions in the Shared Code section of the Design pane. Next, select the New Shared Action button, as provided in the Work pane. The Shared Action properties box displays, as shown in Figure 7.19. After you enter the name for the action and select any other properties that you want to use, you can enter the code for the action in the Programmer's pane. Actions can be made up of simple actions that you select from a list and can contain formulas, LotusScript, or JavaScript.

Figure 7.19. Creating a shared action makes the action reusable in any applicable design element.

graphics/07fig19.jpg

NOTE

Lotus Domino Designer 6 now supports code modules that are larger than 64KB for use in LotusScript, JavaScript, and Java.

 

When all the shared action's action properties, hide-when, and advanced settings are complete, the action can be inserted into a form, page, view, folder, or subform.

NOTE

New to Designer 6 is an action's Display Type property. An action can be a button, check box, or menu separator. A button displays as a button on the top pane of a form. A check box displays an action with a check box to toggle the action off or on. A menu type displays a separator graphic to separate actions that are grouped as a menu. No action code is available for menu type actions.

 

To add a shared action to a form, open the design element that will receive the shared action, open the Action pane, and then choose Create, Action, Insert Shared Action from the menu, as indicated in Figure 7.20. The key here is to place the focus on the Action pane; otherwise , the menu option is unavailable.

Figure 7.20. Choosing Insert Shared Action from the menu provides a list of available actions.

graphics/07fig20.jpg

After it is inserted, the shared action appears on the action bar menu. If it is modified, the shared action is updated in all instances where it is used in a design element. This can save you considerable time when performing database design maintenance.

New to Designer 6 is the sequence Create, Action and then either Action with Subaction or Insert System Action. The Subaction action allows you to nest action items in the Action menu, as shown in Figure 7.21. To add another child subaction underneath an existing child subaction, use Create, Action, Action to continue creating the siblings. To start a new subaction item, again select the Action with Subaction selection from the menu.

Figure 7.21. Choosing Create, Action, Action from Subaction allows you to nest actions under a main action category.

graphics/07fig21.jpg

System actions are actions that previously resided, by default, on the Action menu in R5. In Domino 6, they are called system actions, and they must be added to the Action menu specifically . The system actions are Categorize, Edit Document, Send Document, Forward, Move to Folder, and Remove from Folder.

Part I. Introduction to Release 6

Whats New in Release 6?

The Release 6 Object Store

The Integrated Development Environment

Part II. Foundations of Application Design

Forms Design

Advanced Form Design

Designing Views

Using Shared Resources in Domino Applications

Using the Page Designer

Creating Outlines

Adding Framesets to Domino Applications

Automating Your Application with Agents

Part III. Programming Domino Applications

Using the Formula Language

Real-World Examples Using the Formula Language

Writing LotusScript for Domino Applications

Real-World LotusScript Examples

Writing JavaScript for Domino Applications

Real-World JavaScript Examples

Writing Java for Domino Applications

Real-World Java Examples

Enhancing Domino Applications for the Web

Part IV. Advanced Design Topics

Accessing Data with XML

Accessing Data with DECS and DCRs

Security and Domino Applications

Creating Workflow Applications

Analyzing Domino Applications

Part V. Appendices

Appendix A. HTML Reference

Appendix B. Domino URL Reference



Lotus Notes and Domino 6 Development
Lotus Notes and Domino 6 Development (2nd Edition)
ISBN: 0672325020
EAN: 2147483647
Year: 2005
Pages: 288

Flylib.com © 2008-2020.
If you may any questions please contact us: flylib@qtcs.net