Subforms are forms that you can't use on their own, but that you can directly orprogrammatically insert into a form. In fact, a subform is just a part or segment of a whole form. Subforms provide a way to create reusable segments of a form that can be shared with multiple forms within the application. The process for creating a subform is the same as for creating forms. You can use the same design elements.
Apply a subform to a form by opening a form in design mode and placing the cursor where you want the subform to appear. At the point of insertion, select the Create Insert Subform option from the menu and choose the appropriate subform to place it in the designated location. Figure 7.14 displays the result of adding a subform directly to a form.
Figure 7.14. The RespBanner subform added to the Response form for a discussion database can be used in other forms.
If you add a subform as a computed subform, the subform itself is not displayed, but a placeholder is added instead. By clicking inside the placeholder, you can then add the appropriate formula, as displayed in Figure 7.15. A computed subform allows you to determine which subform is shown based on who the user is, the role he or she belongs to, the contents of a field, or any other condition you can think of. You can even add the day of the week.
Figure 7.15. A computed subform displays a different subform based on the specified condition.
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