Lotus Domino Designer 8: Formula Language

Course Code: DDFL8
Product: Lotus Notes/Domino R8.0.1
Duration: 2 days
Topics/Pages: 11 topics / 198 pages
Price (US dollars):
$45 per user


During this course you will extend your knowledge of the formula language used in Domino applications for both Notes and Web browser clients.

This course doesn't simply regurgitate the Help--it shows you how to do some really interesting and important things in Notes/Domino that just happen to use the formula language. It is not, therefore, a detailed compendium of formula language calls and syntax. Instead, this course focuses on the strategy of using @Functions and @Commands to solve the pivotal issues faced by Domino developers.

Course goals

This course will:

  • extend your knowledge of the formula language
  • build your understanding of data validation and error trapping
  • provide extensive programming and debugging experience to ensure mastery of key @Functions and @Commands
  • use @Functions to operate on multi-value variables and Fields
  • describe how to conditionally execute code based on document state and user identity
  • explain data inheritance and inter-document relationships
  • show how to use well-known locations to store configuration information
  • show how to interact with users with prompts and dialog boxes
  • use mail to send documents between databases.


This course is designed for Notes programmers well versed in using Domino Designer 8. It assumes that you have:

  • thorough knowledge of the Domino Designer development environment, including Form and View design, as well as how to use properties boxes, and how to set the ACL
  • mastered the topics covered in Domino Designer 8: Basic Notes Applications.

Though not required, experience in any computer programming or application scripting language (including spreadsheet formulas) is helpful in understanding how to maximize the use of the formula language.

This course is part of a series of Domino Designer 8 training courses. Follow these paths to master all aspects of developing applications using Domino Designer.

Domino Designer 8: Basic Notes Applications provides the base knowledge for this additional training:
Client Track

    • Configure Domino to use DB2 as a database engine and build applications that access relational data, DB2 for Domino 8 Administrators and Developers.
    • Specialize in programming Notes applications to respond to built-in user interface features, Domino Designer 8: Special Notes Features.
    • Convert an application written for Notes clients to be used in browsers, Domino Designer 8: Basic Browser Applications.
    • Provide data to cutting-edge Web applications, Domino Designer 8: Web Agents and Web Services.

Language Track. These languages apply to both Notes and browser clients:

    • Learn sophisticated application techniques that fully exploit the formula language in Domino Designer 8: Formula Language.
    • Develop sophisticated applications and Agents with LotusScript in Domino Designer 8: LotusScript.
    • Add powerful client-side scripting to browser applications in Domino Designer 8: JavaScript.


This course is sold as a 2-day course.

Course design

This lecture-lab course involves significant hands-on coding experience using the formula language. It only peripherally explores the principles of programming and does not attempt to cover every option of every function.


Topic 1: Using the Formula Language 

Programming languages used in Domino
Advantages of the formula language
Object model programming
Where to use the formula language
Event code interplay
Formula results
Ancillary event triggers
Exercise: Create non-replica copy of DDFL8 Demo
Exercise: Formula return values quiz

Topic 2: Variable and Field Assignment 

Valid variable and Field names
Temporary variables
Self-referential Field events
@ThisName and @GetField
Exercise: @ThisName and @GetField
Set Field values
Append temporary variable and Field values
Formula context
Exercise: Formula context
Reserved and internal Field names
Exercise: Printer-friendly display I
Exercise: Printer-friendly display II

Topic 3: Formula Toolbox 

Matching and equivalence
String matching
String parsing
String replacement
Random number
Time/date functions
Data type conversion
Exercise: Data type conversion
Data testing
DEFAULT keyword

Topic 4: Multi-Value Variables and Fields 

What is a multi-value list?
Multi-value operations and functions
Convert single-value list to multi-value list
Convert a multi-value list to a single-value list
Element count
Select a value from the list
Exercise: @Subset and @Implode
Pair-wise and Permutation operators
Determine if a value is in the list
Replace an item in the list
Minimum and maximum value
Compare ASCII values
Sort a list
Sum a list of numbers
Exercise: Sum a list of numbers
Date range
Dynamic tables
Looping functions
@For loop
Reuse temporary variables
@While loop
Exercise: @While
@DoWhile loop
@Select and @Word

Topic 5: Conditional Evaluation 

Single @If with multiple conditions
Multiple actions using @Do
Aborting execution with @Return
Multiple @If statements
Conditional save and close
Conditional evaluation based on document state
Exercise: Document state
Conditional evaluation based on user identity
Exercise: User rights

Topic 6: Data Inheritance 

Configure inheritance
Inheritance caveats
Conditional inheritance
Exercise: Inheritance
Require inheritance
Disallow pasted documents
Inherit Rich Text
"Inheritance" across databases

Topic 7: Database Lookup 

@Db function overview
Where to use lookup functions
Lookups and security
@DbColumn Function
Static Field lists
External Field lists
Exercise: @DbColumn
@DbLookup function
@DbLookup parameters using Notes
Error trapping
Exercise: @DbLookup
Create unique keys
Return values from multiple source documents
Return multiple values from single source document
Document refresh issue
Limit when lookup is performed
Overcome return data size limits
General lookup performance tips

Topic 8: Document Relationships

When to use Response documents
Design Response document Form
Create Response document
Response document internals
Creating the response hierarchy after the fact
ComposeWithReference flags
Another way to relate documents
Primary key relationship
Field reference by document UNID
Exercise: Document ID relationship
Lookup versus direct Field reference
One-to-many relationships
Updating related documents
"Doclink" to parent

Topic 9: Well-Known Locations 

Well-known location mechanisms
Local NOTES.INI access
Environment function syntax
Environment restrictions
Environment read/set sequence
Exercise: Environment variable
Reading the Windows Registry
Profile documents
Profile documents and security
Create Profile document
Read from Profile document Fields
[NoPersist] option
Exercise: Profile document

Topic 10: User Prompts 

Where you can prompt users
Using the data from prompts and picklists
@Prompt syntax
Password prompt
File prompts
Exercise: @Prompt
@PickList syntax
Exercise: Picklist
Limitations of prompts and picklists
Execution by temporary variables
Preview pane caveat
Where to call @Dialogbox from
@DialogBox syntax
@Dialogbox caveats
Exercise: Dialog box
Optional dialog box keywords
Button type
Which dialog box to use?

Topic 11: Mail Documents

Copying versus mailing documents to other databases
Mail mechanisms
SendTo value
Mailing to a person in your Domino Domain
Mailing to a person in another Domino Domain
Mailing to Internet email address
Mailing to a group
Mailing to a Mail-In Database
Sequence of Group and Mail-in Database resolution
Mail triggers
Trigger 1: Form property
Trigger 2: MailOptions Field
Trigger 3: @Command([MailSend])
Trigger 4: @MailSend without parameters
Exercise: @MailSend without parameters
@MailSend and scheduled Agents
Trigger 5: @MailSend with parameters
Mail-related reserved/system Fields
SaveOptions Field
$AssistMail Field
Fields added by the system
Exercise: @MailSend with parameters
User Mail functions
User Mail commands
Ensure documents are mailed only once
Mail-in database programming
Store Form in document property
Three mail-enabled application models
Resolve duplicate documents