Lotus - Programming Guide, Volume 1 Overview and Formula Language PDF
Lotus - Programming Guide, Volume 1 Overview and Formula Language PDF
Version7
G210-2370-00
Note: Before using this information and the product it supports, read the information in "Notices" at the end of this document.
iii
To enable remote debugging in the agent . . . 58 Numeric constants . . . . . . . . . . . 118
To start the Remote Debugger . . . . . . . 58 Time-date constants . . . . . . . . . . 118
To debug a scheduled LotusScript agent remotely 58 Using operators . . . . . . . . . . . . 120
Debugging Java code remotely . . . . . . . . 59 Operators and precedence . . . . . . . . 120
To enable Java debugging on a Notes client . . 60 Order of evaluation for operations . . . . . 121
To enable Java debugging in an agent, Web Assignment operator . . . . . . . . . . 121
service, or script library . . . . . . . . . 60 List subscript operator . . . . . . . . . 122
To connect a debugger to the JVM . . . . . . 60 List concatenation operator . . . . . . . . 123
Security considerations . . . . . . . . . 61 Unary operators . . . . . . . . . . . 123
Using Script Libraries . . . . . . . . . . . 61 Arithmetic operators . . . . . . . . . . 123
To create a script library . . . . . . . . . 61 Text operator . . . . . . . . . . . . 123
To access an existing script library . . . . . . 62 Comparison operators . . . . . . . . . 123
Incorporating a LotusScript script library . . . 62 Logical operators . . . . . . . . . . . 123
Incorporating a Java script library . . . . . . 62 Operations on lists . . . . . . . . . . 124
Incorporating a Javascript script library . . . . 63 Using @functions . . . . . . . . . . . . 126
Recompiling all LotusScript . . . . . . . . . 63 Syntax . . . . . . . . . . . . . . . 126
To recompile all the LotusScript code in a Return values . . . . . . . . . . . . 126
database . . . . . . . . . . . . . . 64 Side-effects . . . . . . . . . . . . . 127
Writing formulas in the Programmers pane . . . 64 @Commands . . . . . . . . . . . . 127
To enter a formula in the Programmers pane . . 64 Order of evaluation for formula statements . . 128
Using the formula window . . . . . . . . 65 Using reserved words . . . . . . . . . . 129
Using the Programmers pane for Simple action(s) 65 Examples: Using keywords . . . . . . . . 129
Specifying form and view names in formulas . . . 130
Chapter 3. Programming Domino for Debugging formulas . . . . . . . . . . . 130
Web Applications . . . . . . . . . . 67
Formula language . . . . . . . . . . . . 67 Chapter 5. Formula Language Coding
Where formulas work on the Web . . . . . . 67 Guidelines. . . . . . . . . . . . . 133
@Functions on the Web . . . . . . . . . 68 Formulas . . . . . . . . . . . . . . . 133
@Commands on the Web . . . . . . . . . 71 Writing formulas that evaluate to a result . . . 133
Web agents . . . . . . . . . . . . . . 79 Writing formulas that perform actions . . . . 134
Setting up a Web agent . . . . . . . . . 79 Working with lists . . . . . . . . . . . 135
Activating a Web agent . . . . . . . . . 79 Using conditional statements . . . . . . . 138
LotusScript and Java in Web agents . . . . . 80 Using iterative statements . . . . . . . . 139
Examples: Web agents . . . . . . . . . . 80 Writing messages and getting user input . . . . 140
JavaScript . . . . . . . . . . . . . . . 82 Writing messages to the user . . . . . . . 140
JavaScript events . . . . . . . . . . . 83 Getting user input with @Prompt and @PickList 141
JavaScript in HTML . . . . . . . . . . 84 Filling out a form with @DialogBox . . . . . 143
JavaScript object model . . . . . . . . . 86 Getting and setting environment variables . . . 143
Domino objects . . . . . . . . . . . . 90 Handling errors . . . . . . . . . . . . 144
Web services . . . . . . . . . . . . . . 91 Syntax errors . . . . . . . . . . . . 144
Web services terminology. . . . . . . . . 91 Run-time errors . . . . . . . . . . . 144
Web services in Domino Designer . . . . . . 92 Working with @functions . . . . . . . . . 146
Web services on a Domino server . . . . . . 95 Working with @commands . . . . . . . . . 147
Java and LotusScript mappings . . . . . . . 95 Performing string operations . . . . . . . . 148
Examples: Web services . . . . . . . . . 103 Converting data types . . . . . . . . . 148
Examples: Web services data descriptions . . . 107 Concatenating, comparing, and determining
Server configuration for Web browsers . . . . . 111 length . . . . . . . . . . . . . . . 149
The browser.cnf file . . . . . . . . . . 111 Locating and extracting substrings . . . . . 151
Language cross-reference . . . . . . . . 111 Trimming, repeating, adding a new line, and
Dynamic HTML sections. . . . . . . . . 111 changing case . . . . . . . . . . . . 153
Performing arithmetic operations . . . . . . . 154
Chapter 4. Formula Language Rules 113 Examples: Performing arithmetic operations . . 155
Using the syntax rules . . . . . . . . . . 113 Performing time-date operations . . . . . . . 156
Lexical elements . . . . . . . . . . . 113 Examples: Performing time-date operations . . 158
General syntax rules . . . . . . . . . . 114 Accessing the user environment . . . . . . . 158
Using variables . . . . . . . . . . . . . 114 Examples: Accessing the user environment . . 159
Fields . . . . . . . . . . . . . . . 114 Accessing the current database and view . . . . 160
Temporary variables . . . . . . . . . . 116 Database and view attributes . . . . . . . 160
Using constants. . . . . . . . . . . . . 117 Window title and column formula @functions 160
Text constants . . . . . . . . . . . . 117 Examples: Accessing the current database and
view . . . . . . . . . . . . . . . 161
Contents v
Syntax . . . . . . . . . . . . . . . 216 Syntax . . . . . . . . . . . . . . . 226
Parameters . . . . . . . . . . . . . 216 Return value . . . . . . . . . . . . 226
Return value . . . . . . . . . . . . 216 Usage . . . . . . . . . . . . . . . 226
Language cross-reference . . . . . . . . 216 Examples: @ClientType . . . . . . . . . 226
Examples: @AttachmentNames . . . . . . 217 @Command . . . . . . . . . . . . . . 227
@Attachments . . . . . . . . . . . . . 217 Syntax . . . . . . . . . . . . . . . 227
Syntax . . . . . . . . . . . . . . . 217 Usage . . . . . . . . . . . . . . . 227
Parameters . . . . . . . . . . . . . 217 Exceptions . . . . . . . . . . . . . 227
Return value . . . . . . . . . . . . 217 @Compare . . . . . . . . . . . . . . 228
Usage in a Column Formula . . . . . . . 217 Syntax . . . . . . . . . . . . . . . 228
Examples: @Attachments . . . . . . . . 217 Parameters . . . . . . . . . . . . . 228
@Author . . . . . . . . . . . . . . . 217 Return value . . . . . . . . . . . . 228
Syntax . . . . . . . . . . . . . . . 217 Usage . . . . . . . . . . . . . . . 228
Return value . . . . . . . . . . . . 217 Language cross-reference . . . . . . . . 229
Usage . . . . . . . . . . . . . . . 218 Examples: @Compare. . . . . . . . . . 229
Language cross-reference . . . . . . . . 218 @ConfigFile . . . . . . . . . . . . . . 230
Examples: @Author . . . . . . . . . . 218 Syntax . . . . . . . . . . . . . . . 230
@Begins . . . . . . . . . . . . . . . 218 Return value . . . . . . . . . . . . 230
Syntax . . . . . . . . . . . . . . . 218 Usage . . . . . . . . . . . . . . . 230
Parameters . . . . . . . . . . . . . 218 Examples: @ConfigFile . . . . . . . . . 230
Return value . . . . . . . . . . . . 219 @Contains . . . . . . . . . . . . . . 230
Usage . . . . . . . . . . . . . . . 219 Syntax . . . . . . . . . . . . . . . 230
Examples: @Begins . . . . . . . . . . 219 Parameters . . . . . . . . . . . . . 230
@BrowserInfo . . . . . . . . . . . . . 219 Return value . . . . . . . . . . . . 230
Syntax . . . . . . . . . . . . . . . 219 Usage . . . . . . . . . . . . . . . 231
Parameters . . . . . . . . . . . . . 219 Language cross-reference . . . . . . . . 231
Return value . . . . . . . . . . . . 219 Examples: @Contains . . . . . . . . . . 231
Usage . . . . . . . . . . . . . . . 220 @Cos . . . . . . . . . . . . . . . . 231
Language cross-reference . . . . . . . . 220 Syntax . . . . . . . . . . . . . . . 231
Examples: @BrowserInfo . . . . . . . . 220 Parameters . . . . . . . . . . . . . 231
@BusinessDays . . . . . . . . . . . . . 221 Return value . . . . . . . . . . . . 231
Syntax . . . . . . . . . . . . . . 221 Language cross-reference . . . . . . . . 232
Parameters . . . . . . . . . . . . . 221 Examples: @Cos . . . . . . . . . . . 232
Return value . . . . . . . . . . . . 221 @Count . . . . . . . . . . . . . . . 232
Usage . . . . . . . . . . . . . . . 221 Syntax . . . . . . . . . . . . . . . 232
Examples: @BusinessDays . . . . . . . . 221 Parameters . . . . . . . . . . . . . 232
@Certificate . . . . . . . . . . . . . . 222 Return value . . . . . . . . . . . . 232
Syntax . . . . . . . . . . . . . . . 222 Language cross-reference . . . . . . . . 232
Parameters . . . . . . . . . . . . . 222 Examples: @Count. . . . . . . . . . . 232
Return value . . . . . . . . . . . . 223 @Created . . . . . . . . . . . . . . . 233
Usage . . . . . . . . . . . . . . . 223 Syntax . . . . . . . . . . . . . . . 233
Language cross-reference . . . . . . . . 223 Return value . . . . . . . . . . . . 233
Examples: @Certificate . . . . . . . . . 223 Usage . . . . . . . . . . . . . . . 233
@Char . . . . . . . . . . . . . . . . 223 Language cross-reference . . . . . . . . 233
Syntax . . . . . . . . . . . . . . . 223 Examples: @Created . . . . . . . . . . 233
Parameters . . . . . . . . . . . . . 223 @Date . . . . . . . . . . . . . . . . 234
Return value . . . . . . . . . . . . 224 Syntax . . . . . . . . . . . . . . . 234
Usage . . . . . . . . . . . . . . . 224 Parameters . . . . . . . . . . . . . 234
Language cross-reference . . . . . . . . 224 Return value . . . . . . . . . . . . 234
Examples: @Char . . . . . . . . . . . 224 Language cross-reference . . . . . . . . 235
@CheckAlarms . . . . . . . . . . . . . 225 Examples: @Date . . . . . . . . . . . 235
Syntax . . . . . . . . . . . . . . . 225 @Day . . . . . . . . . . . . . . . . 235
Usage . . . . . . . . . . . . . . . 225 Syntax . . . . . . . . . . . . . . . 235
Language cross-reference . . . . . . . . 225 Parameters . . . . . . . . . . . . . 235
@CheckFormulaSyntax . . . . . . . . . . 225 Return value . . . . . . . . . . . . 235
Syntax . . . . . . . . . . . . . . . 225 Language cross-reference . . . . . . . . 235
Parameters . . . . . . . . . . . . . 225 Examples: @Day . . . . . . . . . . . 235
Return value . . . . . . . . . . . . 225 @DB2Schema . . . . . . . . . . . . . 236
Usage . . . . . . . . . . . . . . . 226 Syntax . . . . . . . . . . . . . . . 236
Examples: @CheckFormulaSyntax . . . . . 226 Parameters . . . . . . . . . . . . . 236
@ClientType . . . . . . . . . . . . . . 226 Return value . . . . . . . . . . . . 236
Contents vii
Examples:DEFAULT . . . . . . . . . . 268 Language cross-reference . . . . . . . . 279
@DeleteDocument . . . . . . . . . . . . 269 Examples: @DocLock . . . . . . . . . . 280
Syntax . . . . . . . . . . . . . . . 269 @DocMark . . . . . . . . . . . . . . 280
Usage . . . . . . . . . . . . . . . 269 Syntax . . . . . . . . . . . . . . . 280
Language cross-reference . . . . . . . . 269 Parameters . . . . . . . . . . . . . 280
Examples: @DeleteDocument . . . . . . . 269 Usage . . . . . . . . . . . . . . . 280
@DeleteField . . . . . . . . . . . . . 269 Language cross-reference . . . . . . . . 280
Syntax . . . . . . . . . . . . . . 269 @DocNumber . . . . . . . . . . . . . 281
Usage . . . . . . . . . . . . . . . 269 Syntax . . . . . . . . . . . . . . . 281
Language cross-reference . . . . . . . . 270 Parameters . . . . . . . . . . . . . 281
Examples: @DeleteField . . . . . . . . . 270 Return value . . . . . . . . . . . . 281
@DialogBox . . . . . . . . . . . . . . 270 Usage . . . . . . . . . . . . . . . 281
Syntax . . . . . . . . . . . . . . . 270 Language cross-reference . . . . . . . . 281
Parameters . . . . . . . . . . . . . 270 Examples: @DocNumber . . . . . . . . 281
Return value . . . . . . . . . . . . 271 @DocOmittedLength . . . . . . . . . . . 282
Usage . . . . . . . . . . . . . . . 272 Syntax . . . . . . . . . . . . . . . 282
Sharing of field values . . . . . . . . . 272 Return value . . . . . . . . . . . . 282
Language cross-reference . . . . . . . . 272 Usage . . . . . . . . . . . . . . . 282
Examples: @DialogBox . . . . . . . . . 272 Examples: @DocOmittedLength . . . . . . 282
@Do . . . . . . . . . . . . . . . . 273 @DocParentNumber . . . . . . . . . . . 282
Syntax . . . . . . . . . . . . . . . 273 Syntax . . . . . . . . . . . . . . . 282
Parameters . . . . . . . . . . . . . 273 Parameters . . . . . . . . . . . . . 283
Return value . . . . . . . . . . . . 273 Return value . . . . . . . . . . . . 283
Usage . . . . . . . . . . . . . . . 273 Usage . . . . . . . . . . . . . . . 283
Examples: @Do . . . . . . . . . . . . 273 Language cross-reference . . . . . . . . 283
@DocChildren . . . . . . . . . . . . . 273 Examples: @DocParentNumber . . . . . . 283
Syntax . . . . . . . . . . . . . . . 274 @DocSiblings . . . . . . . . . . . . . 283
Parameters . . . . . . . . . . . . . 274 Syntax . . . . . . . . . . . . . . . 283
Return value . . . . . . . . . . . . 274 Return value . . . . . . . . . . . . 283
Usage . . . . . . . . . . . . . . . 274 Usage . . . . . . . . . . . . . . . 284
Language cross-reference . . . . . . . . 274 Language cross-reference . . . . . . . . 284
Examples: @DocChildren . . . . . . . . 274 Examples: @DocSiblings . . . . . . . . . 284
@DocDescendants . . . . . . . . . . . . 275 @DocumentUniqueID . . . . . . . . . . 284
Syntax . . . . . . . . . . . . . . . 275 Syntax . . . . . . . . . . . . . . . 284
Parameters . . . . . . . . . . . . . 275 Usage . . . . . . . . . . . . . . . 284
Return value . . . . . . . . . . . . 275 Language cross-reference . . . . . . . . 285
Usage . . . . . . . . . . . . . . . 276 Examples: @DocumentUniqueID . . . . . . 285
Language cross-reference . . . . . . . . 276 @Domain . . . . . . . . . . . . . . . 285
Examples: @DocDescendants . . . . . . . 276 Syntax . . . . . . . . . . . . . . . 285
@DocFields . . . . . . . . . . . . . . 276 Return value . . . . . . . . . . . . 286
Syntax . . . . . . . . . . . . . . . 276 Usage . . . . . . . . . . . . . . . 286
Return value . . . . . . . . . . . . 276 Language cross-reference . . . . . . . . 286
Usage . . . . . . . . . . . . . . . 276 Examples: @Domain . . . . . . . . . . 286
Language cross-reference . . . . . . . . 277 @DoWhile . . . . . . . . . . . . . . 286
Examples: @DocFields . . . . . . . . . 277 Syntax . . . . . . . . . . . . . . . 286
@DocLength . . . . . . . . . . . . . . 277 Parameters . . . . . . . . . . . . . 286
Syntax . . . . . . . . . . . . . . 277 Return value . . . . . . . . . . . . 286
Return value . . . . . . . . . . . . 277 Usage . . . . . . . . . . . . . . . 287
Usage . . . . . . . . . . . . . . . 277 Language cross-reference . . . . . . . . 287
Language cross-reference . . . . . . . . 278 Examples: @DoWhile . . . . . . . . . . 287
Examples: @DocLength . . . . . . . . . 278 @EditECL . . . . . . . . . . . . . . 287
@DocLevel . . . . . . . . . . . . . . 278 Syntax . . . . . . . . . . . . . . . 287
Syntax . . . . . . . . . . . . . . . 278 Parameters . . . . . . . . . . . . . 287
Return value . . . . . . . . . . . . 278 Usage . . . . . . . . . . . . . . . 287
Usage . . . . . . . . . . . . . . . 278 Language cross-reference . . . . . . . . 287
Language cross-reference . . . . . . . . 278 Examples: @EditECL . . . . . . . . . . 288
Examples: @DocLevel . . . . . . . . . 278 @EditUserECL . . . . . . . . . . . . . 288
@DocLock . . . . . . . . . . . . . . 279 Syntax . . . . . . . . . . . . . . . 288
Syntax . . . . . . . . . . . . . . . 279 Usage . . . . . . . . . . . . . . . 288
Parameters . . . . . . . . . . . . . 279 Language cross-reference . . . . . . . . 288
Usage . . . . . . . . . . . . . . . 279 @Elements . . . . . . . . . . . . . . 288
Contents ix
Examples: @GetField . . . . . . . . . . 306 Return value . . . . . . . . . . . . 315
@GetFocusTable . . . . . . . . . . . . 306 Usage . . . . . . . . . . . . . . . 316
Syntax . . . . . . . . . . . . . . . 306 Language cross-reference . . . . . . . . 316
Parameters . . . . . . . . . . . . . 306 Examples: @IfError . . . . . . . . . . 316
Return value . . . . . . . . . . . . 307 @Implode . . . . . . . . . . . . . . 316
Usage . . . . . . . . . . . . . . . 307 Syntax . . . . . . . . . . . . . . . 316
Examples: @GetFocusTable . . . . . . . . 307 Parameters . . . . . . . . . . . . . 316
@GetHTTPHeader . . . . . . . . . . . . 307 Return value . . . . . . . . . . . . 317
Syntax . . . . . . . . . . . . . . . 307 Language cross-reference . . . . . . . . 317
Parameters . . . . . . . . . . . . . 307 Examples: @Implode . . . . . . . . . . 317
Return value . . . . . . . . . . . . 308 @InheritedDocumentUniqueID . . . . . . . 317
Usage . . . . . . . . . . . . . . . 308 Syntax . . . . . . . . . . . . . . . 317
Language cross-reference . . . . . . . . 308 Usage . . . . . . . . . . . . . . . 317
Examples: @GetHTTPHeader . . . . . . . 308 Language cross-reference . . . . . . . . 317
@GetIMContactListGroupNames . . . . . . . 308 Examples: @InheritedUniqueID . . . . . . 318
Syntax . . . . . . . . . . . . . . . 308 @Integer . . . . . . . . . . . . . . . 318
Return value . . . . . . . . . . . . 308 Syntax . . . . . . . . . . . . . . . 318
Usage . . . . . . . . . . . . . . . 309 Parameters . . . . . . . . . . . . . 318
@GetPortsList . . . . . . . . . . . . . 309 Return value . . . . . . . . . . . . 318
Syntax . . . . . . . . . . . . . . . 309 Usage . . . . . . . . . . . . . . . 318
Parameters . . . . . . . . . . . . . 309 Language cross-reference . . . . . . . . 318
Return value . . . . . . . . . . . . 309 Examples: @Integer . . . . . . . . . . 319
Usage . . . . . . . . . . . . . . . 309 @IsAgentEnabled . . . . . . . . . . . . 319
Examples: @GetPortsList . . . . . . . . 309 Syntax . . . . . . . . . . . . . . . 319
@GetProfileField . . . . . . . . . . . . 309 Parameters . . . . . . . . . . . . . 319
Syntax . . . . . . . . . . . . . . . 309 Return value . . . . . . . . . . . . 319
Parameters . . . . . . . . . . . . . 310 Usage . . . . . . . . . . . . . . . 319
Return value . . . . . . . . . . . . 310 Language cross-reference . . . . . . . . 319
Usage . . . . . . . . . . . . . . . 310 Examples: @IsAgentEnabled . . . . . . . 319
Language cross-reference . . . . . . . . 310 @IsAppInstalled . . . . . . . . . . . . 320
Examples: @GetProfileField . . . . . . . . 310 Syntax . . . . . . . . . . . . . . . 320
@GetViewInfo . . . . . . . . . . . . . 311 Parameters . . . . . . . . . . . . . 320
Syntax . . . . . . . . . . . . . . . 311 Return value . . . . . . . . . . . . 320
Parameters . . . . . . . . . . . . . 311 Usage . . . . . . . . . . . . . . . 320
Return value . . . . . . . . . . . . 311 @IsAvailable . . . . . . . . . . . . . . 320
Usage . . . . . . . . . . . . . . . 311 Syntax . . . . . . . . . . . . . . . 320
Examples: @GetViewInfo . . . . . . . . 312 Parameters . . . . . . . . . . . . . 320
@HardDeleteDocument . . . . . . . . . . 312 Return value . . . . . . . . . . . . 320
Syntax . . . . . . . . . . . . . . . 312 Usage . . . . . . . . . . . . . . . 320
Usage . . . . . . . . . . . . . . . 312 Language cross-reference . . . . . . . . 321
Language cross-reference . . . . . . . . 312 Examples: @IsAvailable . . . . . . . . . 321
@HashPassword . . . . . . . . . . . . 312 @IsCategory . . . . . . . . . . . . . . 321
Syntax . . . . . . . . . . . . . . . 313 Syntax . . . . . . . . . . . . . . . 321
Parameters . . . . . . . . . . . . . 313 Parameters . . . . . . . . . . . . . 321
Return value . . . . . . . . . . . . 313 Return value . . . . . . . . . . . . 321
Usage . . . . . . . . . . . . . . . 313 Usage . . . . . . . . . . . . . . . 322
@Hour . . . . . . . . . . . . . . . 313 Examples: @IsCategory . . . . . . . . . 322
Syntax . . . . . . . . . . . . . . . 313 @IsDB2 . . . . . . . . . . . . . . . 322
Parameters . . . . . . . . . . . . . 313 Syntax . . . . . . . . . . . . . . . 322
Return value . . . . . . . . . . . . 313 Parameters . . . . . . . . . . . . . 322
Language cross-reference . . . . . . . . 313 Return value . . . . . . . . . . . . 322
Examples: @Hour . . . . . . . . . . . 313 Usage . . . . . . . . . . . . . . . 323
@If . . . . . . . . . . . . . . . . . 314 Examples: @IsDB2 . . . . . . . . . . . 323
Syntax . . . . . . . . . . . . . . . 314 @IsDocBeingEdited . . . . . . . . . . . 323
Parameters . . . . . . . . . . . . . 314 Syntax . . . . . . . . . . . . . . . 323
Usage . . . . . . . . . . . . . . . 314 Return value . . . . . . . . . . . . 323
Language cross-reference . . . . . . . . 314 Usage . . . . . . . . . . . . . . . 323
Examples: @If . . . . . . . . . . . . 314 Language cross-reference . . . . . . . . 324
@IfError . . . . . . . . . . . . . . . 315 Examples: @IsDocBeingEdited . . . . . . . 324
Syntax . . . . . . . . . . . . . . . 315 @IsDocBeingLoaded . . . . . . . . . . . 324
Parameters . . . . . . . . . . . . . 315 Syntax . . . . . . . . . . . . . . . 324
Contents xi
Return value . . . . . . . . . . . . 341 Examples: @LowerCase . . . . . . . . . 352
Usage . . . . . . . . . . . . . . . 341 @MailDbName . . . . . . . . . . . . . 352
Language cross-reference . . . . . . . . 341 Syntax . . . . . . . . . . . . . . . 352
Examples: @LanguagePreference . . . . . . 341 Return value . . . . . . . . . . . . 352
@LaunchApp . . . . . . . . . . . . . 342 Usage . . . . . . . . . . . . . . . 353
Syntax . . . . . . . . . . . . . . . 342 Language cross-reference . . . . . . . . 353
Parameters . . . . . . . . . . . . . 342 Examples: @MailDbName . . . . . . . . 353
Usage . . . . . . . . . . . . . . . 342 @MailEncryptSavedPreference . . . . . . . . 353
Language cross-reference . . . . . . . . 342 Syntax . . . . . . . . . . . . . . . 353
@LDAPServer . . . . . . . . . . . . . 342 Return value . . . . . . . . . . . . 354
Syntax . . . . . . . . . . . . . . . 342 Usage . . . . . . . . . . . . . . . 354
Examples: @LDAPServer . . . . . . . . 342 Examples: @MailEncryptSavedPreference . . . 354
@Left . . . . . . . . . . . . . . . . 342 @MailEncryptSentPreference . . . . . . . . 354
Syntax . . . . . . . . . . . . . . . 343 Syntax . . . . . . . . . . . . . . . 354
Parameters . . . . . . . . . . . . . 343 Return value . . . . . . . . . . . . 354
Return value . . . . . . . . . . . . 343 Usage . . . . . . . . . . . . . . . 354
Language cross-reference . . . . . . . . 343 Language cross-reference . . . . . . . . 354
Examples: @Left . . . . . . . . . . . 343 Examples: @MailEncryptSentPreference . . . . 354
@LeftBack . . . . . . . . . . . . . . 343 @MailSavePreference . . . . . . . . . . . 355
Syntax . . . . . . . . . . . . . . . 343 Syntax . . . . . . . . . . . . . . . 355
Parameters . . . . . . . . . . . . . 343 Return value . . . . . . . . . . . . 355
Return value . . . . . . . . . . . . 344 Usage . . . . . . . . . . . . . . . 355
Language cross-reference . . . . . . . . 344 Language cross-reference . . . . . . . . 355
Examples: @LeftBack . . . . . . . . . . 344 Examples: @MailSavePreference . . . . . . 355
@Length . . . . . . . . . . . . . . . 344 @MailSend . . . . . . . . . . . . . . 355
Syntax . . . . . . . . . . . . . . . 344 Syntax . . . . . . . . . . . . . . 355
Parameters . . . . . . . . . . . . . 344 Parameters . . . . . . . . . . . . . 356
Return value . . . . . . . . . . . . 344 Usage . . . . . . . . . . . . . . . 357
Language cross-reference . . . . . . . . 345 Sending rich text fields . . . . . . . . . 357
Examples: @Length . . . . . . . . . . 345 Mail-related fields in a document . . . . . . 358
@Like . . . . . . . . . . . . . . . . 345 Language cross-reference . . . . . . . . 358
Syntax . . . . . . . . . . . . . . . 345 Examples: @MailSend . . . . . . . . . 358
Parameters . . . . . . . . . . . . . 345 @MailSignPreference . . . . . . . . . . . 358
Return value . . . . . . . . . . . . 345 Syntax . . . . . . . . . . . . . . . 358
Language cross-reference . . . . . . . . 345 Return value . . . . . . . . . . . . 359
Examples: @Like . . . . . . . . . . . 346 Usage . . . . . . . . . . . . . . . 359
@Ln . . . . . . . . . . . . . . . . 346 Language cross-reference . . . . . . . . 359
Syntax . . . . . . . . . . . . . . . 346 Examples: @MailSignPreference . . . . . . 359
Parameters . . . . . . . . . . . . . 346 @Matches . . . . . . . . . . . . . . 359
Return value . . . . . . . . . . . . 346 Syntax . . . . . . . . . . . . . . . 359
Usage . . . . . . . . . . . . . . . 346 Parameters . . . . . . . . . . . . . 359
Language cross-reference . . . . . . . . 346 Return value . . . . . . . . . . . . 359
Examples: @Ln . . . . . . . . . . . . 346 Language cross-reference . . . . . . . . 360
@Locale . . . . . . . . . . . . . . . 346 Examples: @Matches . . . . . . . . . . 360
Syntax . . . . . . . . . . . . . . . 347 @Max . . . . . . . . . . . . . . . . 361
Parameters . . . . . . . . . . . . . 347 Syntax . . . . . . . . . . . . . . . 361
Supported language codes . . . . . . . . 347 Parameters . . . . . . . . . . . . . 361
Language cross-reference . . . . . . . . 350 Return value . . . . . . . . . . . . 361
Examples: @Locale . . . . . . . . . . 350 Usage . . . . . . . . . . . . . . . 361
@Log . . . . . . . . . . . . . . . . 351 Examples: @Max . . . . . . . . . . . 361
Syntax . . . . . . . . . . . . . . . 351 @Member . . . . . . . . . . . . . . 362
Parameters . . . . . . . . . . . . . 351 Syntax . . . . . . . . . . . . . . . 362
Return value . . . . . . . . . . . . 351 Parameters . . . . . . . . . . . . . 362
Usage . . . . . . . . . . . . . . . 351 Return value . . . . . . . . . . . . 362
Examples: @Log . . . . . . . . . . . 351 Examples: @Member . . . . . . . . . . 362
@LowerCase. . . . . . . . . . . . . . 352 @Middle . . . . . . . . . . . . . . . 363
Syntax . . . . . . . . . . . . . . 352 Syntax . . . . . . . . . . . . . . . 363
Parameters . . . . . . . . . . . . . 352 Parameters . . . . . . . . . . . . . 363
Return value . . . . . . . . . . . . 352 Return value . . . . . . . . . . . . 363
Usage . . . . . . . . . . . . . . . 352 Language cross-reference . . . . . . . . 363
Language cross-reference . . . . . . . . 352 Examples: @Middle . . . . . . . . . . 363
Contents xiii
Language cross-reference . . . . . . . . 388 Parameters . . . . . . . . . . . . . 398
@PolicyIsFieldLocked . . . . . . . . . . . 388 Return value . . . . . . . . . . . . 398
Syntax . . . . . . . . . . . . . . 388 Language cross-reference . . . . . . . . 398
Parameters . . . . . . . . . . . . . 388 Examples: @Replace . . . . . . . . . . 398
Return value . . . . . . . . . . . . 388 @ReplaceSubstring . . . . . . . . . . . 399
Usage . . . . . . . . . . . . . . . 388 Syntax . . . . . . . . . . . . . . . 399
Examples: @PolicyIsFieldLocked . . . . . . 388 Parameters . . . . . . . . . . . . . 399
@PostedCommand . . . . . . . . . . . 388 Return value . . . . . . . . . . . . 399
Syntax . . . . . . . . . . . . . . . 388 Usage . . . . . . . . . . . . . . . 399
Paramters . . . . . . . . . . . . . 389 Language cross-reference . . . . . . . . 399
Usage . . . . . . . . . . . . . . . 389 Examples: @ReplaceSubstring . . . . . . . 400
@Power . . . . . . . . . . . . . . . 389 @ReplicaID . . . . . . . . . . . . . . 400
Syntax . . . . . . . . . . . . . . 389 Syntax . . . . . . . . . . . . . . . 400
Parameters . . . . . . . . . . . . . 389 Return value . . . . . . . . . . . . 400
Return value . . . . . . . . . . . . 389 Usage . . . . . . . . . . . . . . . 400
Language cross-reference . . . . . . . . 389 Language cross-reference . . . . . . . . 400
Examples: @Power . . . . . . . . . . 389 Examples: @ReplicaID . . . . . . . . . 400
@Prompt . . . . . . . . . . . . . . . 390 @Responses . . . . . . . . . . . . . . 400
Summary of Dialog Box Styles . . . . . . 390 Syntax . . . . . . . . . . . . . . . 400
Syntax . . . . . . . . . . . . . . . 390 Return value . . . . . . . . . . . . 400
Parameters . . . . . . . . . . . . . 390 Usage . . . . . . . . . . . . . . . 401
Return value . . . . . . . . . . . . 392 Language cross-reference . . . . . . . . 401
Usage . . . . . . . . . . . . . . . 392 Examples: @Responses . . . . . . . . . 401
Language cross-reference . . . . . . . . 392 @Return . . . . . . . . . . . . . . . 401
Examples: @Prompt . . . . . . . . . . 392 Syntax . . . . . . . . . . . . . . 401
@ProperCase . . . . . . . . . . . . . 393 Parameters . . . . . . . . . . . . . 401
Syntax . . . . . . . . . . . . . . . 393 Return value . . . . . . . . . . . . 401
Parameters . . . . . . . . . . . . . 394 Usage . . . . . . . . . . . . . . . 401
Return value . . . . . . . . . . . . 394 Language cross-reference . . . . . . . . 401
Usage . . . . . . . . . . . . . . . 394 Examples: @Return . . . . . . . . . . 401
Language cross-reference . . . . . . . . 394 @Right . . . . . . . . . . . . . . . 402
Examples: @ProperCase . . . . . . . . . 394 Syntax . . . . . . . . . . . . . . . 402
@Random . . . . . . . . . . . . . . 394 Parameters . . . . . . . . . . . . . 402
Syntax . . . . . . . . . . . . . . . 394 Return value . . . . . . . . . . . . 402
Usage . . . . . . . . . . . . . . . 394 Language cross-reference . . . . . . . . 402
Language cross-reference . . . . . . . . 394 Examples: @Right . . . . . . . . . . . 403
Examples: @Random . . . . . . . . . . 394 @RightBack . . . . . . . . . . . . . . 403
@RefreshECL . . . . . . . . . . . . . 395 Syntax . . . . . . . . . . . . . . . 403
Syntax . . . . . . . . . . . . . . . 395 Parameters . . . . . . . . . . . . . 403
Parameters . . . . . . . . . . . . . 395 Return value . . . . . . . . . . . . 403
Usage . . . . . . . . . . . . . . . 395 Language cross-reference . . . . . . . . 403
Examples: @RefreshECL . . . . . . . . . 395 Examples: @RightBack . . . . . . . . . 403
@RegQueryValue . . . . . . . . . . . . 395 @Round . . . . . . . . . . . . . . . 404
Syntax . . . . . . . . . . . . . . . 395 Syntax . . . . . . . . . . . . . . . 404
Parameters . . . . . . . . . . . . . 395 Parameters . . . . . . . . . . . . . 404
Return value . . . . . . . . . . . . 395 Return value . . . . . . . . . . . . 404
Usage . . . . . . . . . . . . . . . 396 Usage . . . . . . . . . . . . . . . 404
Examples: @RegQueryValue . . . . . . . 396 Language cross-reference . . . . . . . . 404
REM . . . . . . . . . . . . . . . . 396 Examples: @Round . . . . . . . . . . 404
Syntax . . . . . . . . . . . . . . . 396 @Second . . . . . . . . . . . . . . . 405
Usage . . . . . . . . . . . . . . . 396 Syntax . . . . . . . . . . . . . . . 405
Language cross-reference . . . . . . . . 396 Parameters . . . . . . . . . . . . . 405
Examples: REM . . . . . . . . . . . 396 Return value . . . . . . . . . . . . 405
@Repeat . . . . . . . . . . . . . . . 397 Language cross-reference . . . . . . . . 405
Parameters . . . . . . . . . . . . . 397 Examples: @Second . . . . . . . . . . 405
Return value . . . . . . . . . . . . 397 SELECT . . . . . . . . . . . . . . . 405
Usage . . . . . . . . . . . . . . . 397 Syntax . . . . . . . . . . . . . . . 405
Language cross-reference . . . . . . . . 397 Usage . . . . . . . . . . . . . . . 406
Examples: @Repeat . . . . . . . . . . 397 Language cross-reference . . . . . . . . 406
@Replace . . . . . . . . . . . . . . . 398 Examples: SELECT . . . . . . . . . . 406
Syntax . . . . . . . . . . . . . . . 398 @Select . . . . . . . . . . . . . . . 407
Contents xv
@Text . . . . . . . . . . . . . . . . 426 Language cross-reference . . . . . . . . 436
Syntax . . . . . . . . . . . . . . . 426 Examples: @Today . . . . . . . . . . . 436
Parameters . . . . . . . . . . . . . 426 @Tomorrow . . . . . . . . . . . . . . 436
Return value . . . . . . . . . . . . 426 Syntax . . . . . . . . . . . . . . . 436
@Text with timedate components . . . . . 426 Return value . . . . . . . . . . . . 436
@Text with number values . . . . . . . . 427 Usage . . . . . . . . . . . . . . . 436
Usage . . . . . . . . . . . . . . . 427 Language cross-reference . . . . . . . . 437
Language cross-reference . . . . . . . . 428 Examples: @Tomorrow . . . . . . . . . 437
Examples: @Text . . . . . . . . . . . 428 @ToNumber . . . . . . . . . . . . . . 437
@TextToNumber . . . . . . . . . . . . 428 Syntax . . . . . . . . . . . . . . . 437
Syntax . . . . . . . . . . . . . . . 428 Parameters . . . . . . . . . . . . . 437
Parameters . . . . . . . . . . . . . 428 Return value . . . . . . . . . . . . 437
Return value . . . . . . . . . . . . 429 Usage . . . . . . . . . . . . . . . 437
Usage . . . . . . . . . . . . . . . 429 Language cross-reference . . . . . . . . 437
Language cross-reference . . . . . . . . 429 Examples: @ToNumber . . . . . . . . . 438
Examples: @TextToNumber . . . . . . . . 429 @ToTime . . . . . . . . . . . . . . . 438
@TextToTime . . . . . . . . . . . . . 429 Syntax . . . . . . . . . . . . . . . 438
Syntax . . . . . . . . . . . . . . . 429 Parameters . . . . . . . . . . . . . 438
Parameters . . . . . . . . . . . . . 429 Return value . . . . . . . . . . . . 438
Return value . . . . . . . . . . . . 429 Usage . . . . . . . . . . . . . . . 438
Usage . . . . . . . . . . . . . . . 430 Language cross-reference . . . . . . . . 438
Language cross-reference . . . . . . . . 430 Examples: @ToTime . . . . . . . . . . 438
Examples: @TextToTime . . . . . . . . . 430 @Transform . . . . . . . . . . . . . . 438
@ThisName . . . . . . . . . . . . . . 430 Syntax . . . . . . . . . . . . . . . 439
Syntax . . . . . . . . . . . . . . . 430 Parameters . . . . . . . . . . . . . 439
Return value . . . . . . . . . . . . 430 Return value . . . . . . . . . . . . 439
Usage . . . . . . . . . . . . . . . 430 Usage . . . . . . . . . . . . . . . 439
Language cross-reference . . . . . . . . 430 Language cross-reference . . . . . . . . 439
Examples: @ThisName . . . . . . . . . 431 Examples: @Transform . . . . . . . . . 439
@ThisValue . . . . . . . . . . . . . . 431 @Trim . . . . . . . . . . . . . . . . 440
Syntax . . . . . . . . . . . . . . . 431 Syntax . . . . . . . . . . . . . . . 440
Return value . . . . . . . . . . . . 431 Parameters . . . . . . . . . . . . . 440
Usage . . . . . . . . . . . . . . . 431 Return value . . . . . . . . . . . . 440
Language cross-reference . . . . . . . . 431 Usage . . . . . . . . . . . . . . . 440
Examples: @ThisValue . . . . . . . . . 431 Language cross-reference . . . . . . . . 440
@Time . . . . . . . . . . . . . . . . 431 Examples: @Trim . . . . . . . . . . . 440
Syntax . . . . . . . . . . . . . . . 432 @True . . . . . . . . . . . . . . . . 440
Parameters . . . . . . . . . . . . . 432 Syntax . . . . . . . . . . . . . . . 440
Return value . . . . . . . . . . . . 432 Return value . . . . . . . . . . . . 441
Language cross-reference . . . . . . . . 432 Language cross-reference . . . . . . . . 441
Examples: @Time . . . . . . . . . . . 432 Examples: @True . . . . . . . . . . . 441
@TimeMerge . . . . . . . . . . . . . 433 @Unavailable . . . . . . . . . . . . . 441
Syntax . . . . . . . . . . . . . . . 433 Syntax . . . . . . . . . . . . . . 441
Parameters . . . . . . . . . . . . . 433 Usage . . . . . . . . . . . . . . . 441
Return value . . . . . . . . . . . . 433 Language cross-reference . . . . . . . . 441
Examples: @TimeMerge . . . . . . . . . 433 Examples: @Unavailable . . . . . . . . . 441
@TimeToTextInZone . . . . . . . . . . . 433 @UndeleteDocument . . . . . . . . . . . 442
Syntax . . . . . . . . . . . . . . . 433 Syntax . . . . . . . . . . . . . . . 442
Parameters . . . . . . . . . . . . . 433 Usage . . . . . . . . . . . . . . . 442
Return value . . . . . . . . . . . . 434 Examples: @UndeleteDocument . . . . . . 442
Examples: @TimeToTextInZone . . . . . . 434 @Unique . . . . . . . . . . . . . . . 442
@TimeZoneToText . . . . . . . . . . . . 434 Syntax . . . . . . . . . . . . . . . 442
Syntax . . . . . . . . . . . . . . . 434 Parameters . . . . . . . . . . . . . 442
Parameters . . . . . . . . . . . . . 435 Return value . . . . . . . . . . . . 442
Return value . . . . . . . . . . . . 435 Usage . . . . . . . . . . . . . . . 443
Usage . . . . . . . . . . . . . . . 435 Language cross-reference . . . . . . . . 443
Examples: @TimeZoneToText . . . . . . . 435 Examples: @Unique . . . . . . . . . . 443
@Today . . . . . . . . . . . . . . . 435 @UpdateFormulaContext . . . . . . . . . 443
Syntax . . . . . . . . . . . . . . . 435 Syntax . . . . . . . . . . . . . . . 443
Return value . . . . . . . . . . . . 436 Usage . . . . . . . . . . . . . . . 443
Usage . . . . . . . . . . . . . . . 436 Examples: @UpdateFormulaContext . . . . . 443
Contents xvii
Syntax . . . . . . . . . . . . . . 466 Language cross-reference . . . . . . . . 473
Return value . . . . . . . . . . . . 466 Examples: @Zone . . . . . . . . . . . 474
Usage . . . . . . . . . . . . . . . 466
Language cross-reference . . . . . . . . 466 Chapter 7. Formula Language
Examples: @ViewTitle . . . . . . . . . 466 @Commands A-Z. . . . . . . . . . 475
@WebDbName . . . . . . . . . . . . . 467
Using @Commands . . . . . . . . . . . 475
Syntax . . . . . . . . . . . . . . 467
Syntax . . . . . . . . . . . . . . . 475
Return value . . . . . . . . . . . . 467
Parameters . . . . . . . . . . . . . 475
Usage . . . . . . . . . . . . . . . 467
Return value . . . . . . . . . . . . 475
Language cross-reference . . . . . . . . 467
@Commands with ECL security . . . . . . . 475
Examples: @WebDbName . . . . . . . . 467
AddBookmark @Command . . . . . . . . . 477
@Weekday . . . . . . . . . . . . . . 467
Syntax . . . . . . . . . . . . . . 477
Syntax . . . . . . . . . . . . . . . 467
Parameters . . . . . . . . . . . . . 477
Parameters . . . . . . . . . . . . . 468
Usage . . . . . . . . . . . . . . . 478
Return value . . . . . . . . . . . . 468
Examples: AddBookmark . . . . . . . . 478
Language cross-reference . . . . . . . . 468
AddDatabase @Command . . . . . . . . . 478
Examples: @Weekday. . . . . . . . . . 468
Syntax . . . . . . . . . . . . . . 478
@While . . . . . . . . . . . . . . . 468
Parameters . . . . . . . . . . . . . 478
Syntax . . . . . . . . . . . . . . . 468
Usage . . . . . . . . . . . . . . . 478
Parameters . . . . . . . . . . . . . 468
Language cross-reference . . . . . . . . 478
Return value . . . . . . . . . . . . 468
Examples: AddDatabase . . . . . . . . . 479
Usage . . . . . . . . . . . . . . . 468
AddDatabaseRepID @Command . . . . . . . 479
Language cross-reference . . . . . . . . 469
Syntax . . . . . . . . . . . . . . 479
Examples: @While . . . . . . . . . . . 469
Parameters . . . . . . . . . . . . . 479
@Wide. . . . . . . . . . . . . . . . 469
Usage . . . . . . . . . . . . . . . 479
Syntax . . . . . . . . . . . . . . . 469
AddToIMContactList @Command . . . . . . 479
Parameters . . . . . . . . . . . . . 469
Syntax . . . . . . . . . . . . . . 479
Return value . . . . . . . . . . . . 469
Parameters . . . . . . . . . . . . . 480
Usage . . . . . . . . . . . . . . . 469
AdminCertify @Command . . . . . . . . . 480
Language cross-reference . . . . . . . . 469
Syntax . . . . . . . . . . . . . . . 480
Examples: @Wide . . . . . . . . . . . 469
Usage . . . . . . . . . . . . . . . 480
@Word . . . . . . . . . . . . . . . 470
Language cross-reference . . . . . . . . 480
Syntax . . . . . . . . . . . . . . . 470
AdminCreateGroup @Command . . . . . . . 480
Return value . . . . . . . . . . . . 470
Syntax . . . . . . . . . . . . . . 480
Language cross-reference . . . . . . . . 470
Usage . . . . . . . . . . . . . . . 480
Examples: @Word . . . . . . . . . . . 470
AdminCrossCertifyIDFile @Command . . . . . 480
@Year . . . . . . . . . . . . . . . . 471
Syntax . . . . . . . . . . . . . . 481
Syntax . . . . . . . . . . . . . . . 471
Usage . . . . . . . . . . . . . . . 481
Parameters . . . . . . . . . . . . . 471
Language cross-reference . . . . . . . . 481
Return value . . . . . . . . . . . . 471
AdminCrossCertifyKey @Command . . . . . . 481
Language cross-reference . . . . . . . . 471
Syntax . . . . . . . . . . . . . . 481
Examples: @Year . . . . . . . . . . . 471
Usage . . . . . . . . . . . . . . . 481
@Yes . . . . . . . . . . . . . . . . 471
AdminDatabaseAnalysis @Command . . . . . 481
Syntax . . . . . . . . . . . . . . 471
Syntax . . . . . . . . . . . . . . . 481
Return value . . . . . . . . . . . . 471
Usage . . . . . . . . . . . . . . . 481
Usage . . . . . . . . . . . . . . . 471
AdminDatabaseQuotas @Command . . . . . . 481
Language cross-reference . . . . . . . . 471
Syntax . . . . . . . . . . . . . . . 481
Examples: @Yes . . . . . . . . . . . 471
Usage . . . . . . . . . . . . . . . 481
@Yesterday . . . . . . . . . . . . . . 472
Language cross-reference . . . . . . . . 482
Syntax . . . . . . . . . . . . . . 472
AdminIDFileClearPassword @Command . . . . 482
Return value . . . . . . . . . . . . 472
Syntax . . . . . . . . . . . . . . 482
Usage . . . . . . . . . . . . . . . 472
Usage . . . . . . . . . . . . . . . 482
Language cross-reference . . . . . . . . 472
AdminIDFileExamine @Command . . . . . . 482
Examples: @Yesterday . . . . . . . . . 472
Syntax . . . . . . . . . . . . . . . 482
@Zone . . . . . . . . . . . . . . . . 472
Usage . . . . . . . . . . . . . . . 482
Syntax . . . . . . . . . . . . . . . 472
AdminIDFileSetPassword @Command . . . . . 482
Parameters . . . . . . . . . . . . . 472
Syntax . . . . . . . . . . . . . . . 482
Return value . . . . . . . . . . . . 472
Usage . . . . . . . . . . . . . . . 482
Usage . . . . . . . . . . . . . . . 473
Administration @Command . . . . . . . . 482
Time zones that are not full-hour increments
Syntax . . . . . . . . . . . . . . . 482
from GMT . . . . . . . . . . . . . 473
Usage . . . . . . . . . . . . . . . 482
Contents xix
Usage . . . . . . . . . . . . . . . 495 Usage . . . . . . . . . . . . . . . 503
Language cross-reference . . . . . . . . 495 CreateSection @Command . . . . . . . . . 503
Clear @Command . . . . . . . . . . . . 495 Syntax . . . . . . . . . . . . . . 503
Syntax . . . . . . . . . . . . . . . 495 Usage . . . . . . . . . . . . . . . 503
Usage . . . . . . . . . . . . . . . 495 CreateSubform @Command . . . . . . . . 503
Language cross-reference . . . . . . . . 495 Syntax . . . . . . . . . . . . . . 503
Examples: Clear . . . . . . . . . . . 496 Usage . . . . . . . . . . . . . . . 503
CloseWindow @Command . . . . . . . . . 496 CreateTextbox @Command . . . . . . . . . 504
Syntax . . . . . . . . . . . . . . . 496 Syntax . . . . . . . . . . . . . . . 504
Usage . . . . . . . . . . . . . . . 496 Usage . . . . . . . . . . . . . . . 504
Language cross-reference . . . . . . . . 496 CreateView @Command . . . . . . . . . . 504
Examples: @Command([CloseWindow]) . . . 496 Syntax . . . . . . . . . . . . . . . 504
Compose @Command . . . . . . . . . . 496 Usage . . . . . . . . . . . . . . . 504
Syntax . . . . . . . . . . . . . . 496 Language cross-reference . . . . . . . . 504
Parameters . . . . . . . . . . . . . 496 DatabaseDelete @Command . . . . . . . . 504
Usage . . . . . . . . . . . . . . . 497 Syntax . . . . . . . . . . . . . . . 504
Language cross-reference . . . . . . . . 497 Usage . . . . . . . . . . . . . . . 504
Examples: Compose . . . . . . . . . . 497 Language cross-reference . . . . . . . . 505
ComposeWithReference @Command . . . . . 498 DatabaseReplSettings @Command . . . . . . 505
Syntax . . . . . . . . . . . . . . 498 Syntax . . . . . . . . . . . . . . . 505
Parameters . . . . . . . . . . . . . 498 Usage . . . . . . . . . . . . . . . 505
Usage . . . . . . . . . . . . . . . 498 DebugLotusScript @Command . . . . . . . 505
Language cross-reference . . . . . . . . 499 Syntax . . . . . . . . . . . . . . 505
Examples: ComposeWithReference . . . . . 499 Usage . . . . . . . . . . . . . . . 505
CreateAction @Command . . . . . . . . . 500 Examples: @Command([DebugLotusScript]) . . 505
Syntax . . . . . . . . . . . . . . . 500 DesignDocumentInfo @Command . . . . . . 505
Usage . . . . . . . . . . . . . . . 500 Syntax . . . . . . . . . . . . . . . 505
CreateAgent @Command . . . . . . . . . 500 Usage . . . . . . . . . . . . . . . 506
Syntax . . . . . . . . . . . . . . 500 DesignFormAttributes @Command . . . . . . 506
Usage . . . . . . . . . . . . . . . 500 Syntax . . . . . . . . . . . . . . . 506
CreateControlledAccessSection @Command . . . 500 Usage . . . . . . . . . . . . . . . 506
Syntax . . . . . . . . . . . . . . . 500 DesignFormFieldDef @Command . . . . . . 506
Usage . . . . . . . . . . . . . . . 500 Syntax . . . . . . . . . . . . . . . 506
CreateEllipse @Command . . . . . . . . . 500 Usage . . . . . . . . . . . . . . . 506
Syntax . . . . . . . . . . . . . . 500 DesignFormNewField @Command . . . . . . 506
Usage . . . . . . . . . . . . . . . 501 Syntax . . . . . . . . . . . . . . . 506
CreateFolder @Command . . . . . . . . . 501 Usage . . . . . . . . . . . . . . . 506
Syntax . . . . . . . . . . . . . . 501 DesignForms @Command . . . . . . . . . 506
Usage . . . . . . . . . . . . . . . 501 Syntax . . . . . . . . . . . . . . 507
Language cross-reference . . . . . . . . 501 Usage . . . . . . . . . . . . . . . 507
CreateForm @Command . . . . . . . . . . 501 DesignFormShareField @Command . . . . . . 507
Syntax . . . . . . . . . . . . . . 501 Syntax . . . . . . . . . . . . . . . 507
Usage . . . . . . . . . . . . . . . 501 Usage . . . . . . . . . . . . . . . 507
CreateLayoutRegion @Command . . . . . . . 501 DesignFormUseField @Command . . . . . . 507
Syntax . . . . . . . . . . . . . . 501 Syntax . . . . . . . . . . . . . . . 507
Usage . . . . . . . . . . . . . . . 501 Usage . . . . . . . . . . . . . . . 507
CreateNavigator @Command . . . . . . . . 502 DesignFormWindowTitle @Command . . . . . 507
Syntax . . . . . . . . . . . . . . . 502 Syntax . . . . . . . . . . . . . . . 507
Usage . . . . . . . . . . . . . . . 502 Usage . . . . . . . . . . . . . . . 507
Language cross-reference . . . . . . . . 502 DesignHelpAboutDocument @Command . . . . 507
CreatePolygon @Command . . . . . . . . . 502 Syntax . . . . . . . . . . . . . . . 508
Syntax . . . . . . . . . . . . . . 502 Usage . . . . . . . . . . . . . . . 508
Usage . . . . . . . . . . . . . . . 502 DesignHelpUsingDocument @Command . . . . 508
CreatePolyline @Command . . . . . . . . . 502 Syntax . . . . . . . . . . . . . . . 508
Syntax . . . . . . . . . . . . . . 502 Usage . . . . . . . . . . . . . . . 508
Usage . . . . . . . . . . . . . . . 502 DesignIcon @Command . . . . . . . . . . 508
CreateRectangle @Command . . . . . . . . 502 Syntax . . . . . . . . . . . . . . . 508
Syntax . . . . . . . . . . . . . . 503 Usage . . . . . . . . . . . . . . . 508
Usage . . . . . . . . . . . . . . . 503 DesignMacros @Command . . . . . . . . . 508
CreateRectangularHotspot @Command . . . . . 503 Syntax . . . . . . . . . . . . . . . 508
Syntax . . . . . . . . . . . . . . 503 Usage . . . . . . . . . . . . . . . 508
Contents xxi
Usage . . . . . . . . . . . . . . . 521 Syntax . . . . . . . . . . . . . . . 527
Language cross-reference . . . . . . . . 521 Usage . . . . . . . . . . . . . . . 527
EditInsertButton @Command . . . . . . . . 521 Language cross-reference . . . . . . . . 528
Syntax . . . . . . . . . . . . . . . 521 EditPasteSpecial @Command . . . . . . . . 528
Usage . . . . . . . . . . . . . . . 522 Syntax . . . . . . . . . . . . . . . 528
EditInsertFileAttachment @Command . . . . . 522 Usage . . . . . . . . . . . . . . . 528
Syntax . . . . . . . . . . . . . . 522 EditPhoneNumbers @Command . . . . . . . 528
Parameters . . . . . . . . . . . . . 522 Syntax . . . . . . . . . . . . . . . 528
Usage . . . . . . . . . . . . . . . 522 Usage . . . . . . . . . . . . . . . 528
Language cross-reference . . . . . . . . 522 EditPrevField @Command . . . . . . . . . 528
Examples: EditInsertFileAttachment . . . . . 522 Syntax . . . . . . . . . . . . . . . 528
EditInsertObject @Command . . . . . . . . 522 Usage . . . . . . . . . . . . . . . 528
Syntax . . . . . . . . . . . . . . . 523 Language cross-reference . . . . . . . . 528
Parameters . . . . . . . . . . . . . 523 EditProfile @Command . . . . . . . . . . 528
Usage . . . . . . . . . . . . . . . 523 Syntax . . . . . . . . . . . . . . . 529
Language cross-reference . . . . . . . . 523 Parameters . . . . . . . . . . . . . 529
Examples: EditInsertObject . . . . . . . . 523 Language cross-reference . . . . . . . . 529
EditInsertPageBreak @Command . . . . . . . 523 Examples: EditProfile . . . . . . . . . . 529
Syntax . . . . . . . . . . . . . . . 523 EditProfileDocument @Command . . . . . . 529
Usage . . . . . . . . . . . . . . . 523 Syntax . . . . . . . . . . . . . . . 530
Language cross-reference . . . . . . . . 523 Parameters . . . . . . . . . . . . . 530
EditInsertPopup @Command . . . . . . . . 524 Language cross-reference . . . . . . . . 530
Syntax . . . . . . . . . . . . . . . 524 EditQuoteSelection @Command . . . . . . . 530
Usage . . . . . . . . . . . . . . . 524 Syntax . . . . . . . . . . . . . . . 530
EditInsertTable @Command . . . . . . . . 524 Usage . . . . . . . . . . . . . . . 530
Syntax . . . . . . . . . . . . . . . 524 Examples: EditQuoteSelection . . . . . . . 531
Usage . . . . . . . . . . . . . . . 524 EditResizePicture @Command . . . . . . . . 531
Language cross-reference . . . . . . . . 524 Syntax . . . . . . . . . . . . . . . 531
EditInsertText @Command . . . . . . . . . 524 Usage . . . . . . . . . . . . . . . 531
Syntax . . . . . . . . . . . . . . . 524 EditRestoreDocument @Command . . . . . . 531
Parameters . . . . . . . . . . . . . 524 Syntax . . . . . . . . . . . . . . . 531
Usage . . . . . . . . . . . . . . . 525 Usage . . . . . . . . . . . . . . . 531
Language cross-reference . . . . . . . . 525 Examples: @Command([EditRestoreDocument]) 531
Examples: EditInsertText . . . . . . . . 525 EditRight @Command . . . . . . . . . . 532
EditLeft @Command . . . . . . . . . . . 525 Syntax . . . . . . . . . . . . . . . 532
Syntax . . . . . . . . . . . . . . . 525 Parameters . . . . . . . . . . . . . 532
Parameters . . . . . . . . . . . . . 525 Usage . . . . . . . . . . . . . . . 532
Usage . . . . . . . . . . . . . . . 525 Language cross-reference . . . . . . . . 532
Language cross-reference . . . . . . . . 525 Examples: EditRight . . . . . . . . . . 532
Examples: EditLeft . . . . . . . . . . 525 EditSelectAll @Command . . . . . . . . . 532
EditLinks @Command . . . . . . . . . . 525 Syntax . . . . . . . . . . . . . . . 532
Syntax . . . . . . . . . . . . . . . 526 Usage . . . . . . . . . . . . . . . 532
Usage . . . . . . . . . . . . . . . 526 Language cross-reference . . . . . . . . 533
Language cross-reference . . . . . . . . 526 Examples: EditSelectAll command . . . . . 533
EditLocations @Command . . . . . . . . . 526 EditSelectByDate @Command . . . . . . . . 533
Syntax . . . . . . . . . . . . . . . 526 Syntax . . . . . . . . . . . . . . . 533
Usage . . . . . . . . . . . . . . . 526 Usage . . . . . . . . . . . . . . . 533
EditMakeDocLink @Command . . . . . . . 526 Language cross-reference . . . . . . . . 533
Syntax . . . . . . . . . . . . . . . 526 EditShowHideHiddenChars @Command . . . . 533
Usage . . . . . . . . . . . . . . . 526 Syntax . . . . . . . . . . . . . . . 533
Language cross-reference . . . . . . . . 526 Parameters . . . . . . . . . . . . . 533
Examples: @Command([EditMakeDocLink]) . . 527 Usage . . . . . . . . . . . . . . . 534
EditNextField @Command . . . . . . . . . 527 Language cross-reference . . . . . . . . 534
Syntax . . . . . . . . . . . . . . . 527 EditTableDeleteRowColumn @Command . . . . 534
Usage . . . . . . . . . . . . . . . 527 Syntax . . . . . . . . . . . . . . . 534
Language cross-reference . . . . . . . . 527 Usage . . . . . . . . . . . . . . . 534
EditOpenLink @Command . . . . . . . . . 527 Language cross-reference . . . . . . . . 534
Syntax . . . . . . . . . . . . . . . 527 EditTableFormat @Command . . . . . . . . 534
Usage . . . . . . . . . . . . . . . 527 Syntax . . . . . . . . . . . . . . . 534
Language cross-reference . . . . . . . . 527 Usage . . . . . . . . . . . . . . . 534
EditPaste @Command . . . . . . . . . . 527 Language cross-reference . . . . . . . . 534
Contents xxiii
Usage . . . . . . . . . . . . . . . 549 FolderRename @Command . . . . . . . . . 558
Language cross-reference . . . . . . . . 550 Syntax . . . . . . . . . . . . . . . 559
Examples: FileOpenDBRepID . . . . . . . 550 Usage . . . . . . . . . . . . . . . 559
FilePageSetup @Command . . . . . . . . . 550 Language cross-reference . . . . . . . . 559
Syntax . . . . . . . . . . . . . . . 550 FormActions @Command . . . . . . . . . 559
Usage . . . . . . . . . . . . . . . 550 Syntax . . . . . . . . . . . . . . . 559
Language cross-reference . . . . . . . . 550 Usage . . . . . . . . . . . . . . . 559
FilePrint @Command . . . . . . . . . . . 550 FormTestDocument @Command . . . . . . . 559
Syntax . . . . . . . . . . . . . . . 550 Syntax . . . . . . . . . . . . . . . 559
Parameters . . . . . . . . . . . . . 550 Usage . . . . . . . . . . . . . . . 559
Usage . . . . . . . . . . . . . . . 551 GoUpLevel @Command . . . . . . . . . . 559
Language cross-reference . . . . . . . . 552 Syntax . . . . . . . . . . . . . . . 559
Examples: FilePrint @Command . . . . . . 552 Usage . . . . . . . . . . . . . . . 559
FilePrintSetup @Command . . . . . . . . . 552 Language cross-reference . . . . . . . . 559
Syntax . . . . . . . . . . . . . . . 552 HelpAboutDatabase @Command . . . . . . . 560
Usage . . . . . . . . . . . . . . . 552 Syntax . . . . . . . . . . . . . . . 560
Language cross-reference . . . . . . . . 552 Usage . . . . . . . . . . . . . . . 560
FileSave @Command . . . . . . . . . . . 552 HelpAboutNotes @Command . . . . . . . . 560
Syntax . . . . . . . . . . . . . . . 552 Syntax . . . . . . . . . . . . . . . 560
Usage . . . . . . . . . . . . . . . 553 Usage . . . . . . . . . . . . . . . 560
Language cross-reference . . . . . . . . 553 HelpUsingDatabase @Command . . . . . . . 560
Examples: FileSave . . . . . . . . . . 553 Syntax . . . . . . . . . . . . . . . 560
FileSaveNewVersion @Command . . . . . . . 553 Usage . . . . . . . . . . . . . . . 560
Syntax . . . . . . . . . . . . . . . 553 HotspotClear @Command . . . . . . . . . 560
Usage . . . . . . . . . . . . . . . 553 Syntax . . . . . . . . . . . . . . . 560
Language cross-reference . . . . . . . . 553 Usage . . . . . . . . . . . . . . . 561
FindFreeTimeDialog @Command . . . . . . . 553 Language cross-reference . . . . . . . . 561
Language cross-reference . . . . . . . . 555 HotspotProperties @Command . . . . . . . 561
Examples: FindFreeTimeDialog . . . . . . 555 Syntax . . . . . . . . . . . . . . . 561
Folder @Command . . . . . . . . . . . 555 Usage . . . . . . . . . . . . . . . 561
Syntax . . . . . . . . . . . . . . . 555 Language cross-reference . . . . . . . . 561
Parameters . . . . . . . . . . . . . 555 InsertSubform @Command . . . . . . . . . 561
Usage . . . . . . . . . . . . . . . 555 Syntax . . . . . . . . . . . . . . . 561
Language cross-reference . . . . . . . . 556 Usage . . . . . . . . . . . . . . . 561
FolderCollapse @Command . . . . . . . . 556 LayoutAddGraphic @Command . . . . . . . 561
Syntax . . . . . . . . . . . . . . . 556 Syntax . . . . . . . . . . . . . . . 562
Usage . . . . . . . . . . . . . . . 556 Usage . . . . . . . . . . . . . . . 562
FolderCustomize @Command . . . . . . . . 556 LayoutAddText @Command . . . . . . . . 562
Syntax . . . . . . . . . . . . . . . 556 Syntax . . . . . . . . . . . . . . . 562
Usage . . . . . . . . . . . . . . . 556 Usage . . . . . . . . . . . . . . . 562
FolderDocuments @Command. . . . . . . . 556 LayoutElementBringToFront @Command . . . . 562
Syntax . . . . . . . . . . . . . . . 556 Syntax . . . . . . . . . . . . . . . 562
Parameters . . . . . . . . . . . . . 556 Usage . . . . . . . . . . . . . . . 562
Usage . . . . . . . . . . . . . . . 557 LayoutElementProperties @Command . . . . . 562
Language cross-reference . . . . . . . . 557 Syntax . . . . . . . . . . . . . . . 562
FolderExpand @Command . . . . . . . . . 557 Usage . . . . . . . . . . . . . . . 562
Syntax . . . . . . . . . . . . . . . 557 LayoutElementSendToBack @Command . . . . 562
Usage . . . . . . . . . . . . . . . 557 Syntax . . . . . . . . . . . . . . . 563
FolderExpandAll @Command . . . . . . . . 557 Usage . . . . . . . . . . . . . . . 563
Syntax . . . . . . . . . . . . . . . 557 LayoutProperties @Command . . . . . . . . 563
Usage . . . . . . . . . . . . . . . 558 Syntax . . . . . . . . . . . . . . . 563
FolderExpandWithChildren @Command . . . . 558 Usage . . . . . . . . . . . . . . . 563
Syntax . . . . . . . . . . . . . . . 558 MailAddress @Command . . . . . . . . . 563
Usage . . . . . . . . . . . . . . . 558 Syntax . . . . . . . . . . . . . . . 563
FolderMove @Command . . . . . . . . . 558 Usage . . . . . . . . . . . . . . . 563
Syntax . . . . . . . . . . . . . . . 558 Examples: @Command([MailAddress]) . . . . 563
Usage . . . . . . . . . . . . . . . 558 MailComposeMemo @Command . . . . . . . 563
FolderProperties @Command . . . . . . . . 558 Syntax . . . . . . . . . . . . . . . 564
Syntax . . . . . . . . . . . . . . . 558 Usage . . . . . . . . . . . . . . . 564
Usage . . . . . . . . . . . . . . . 558 Examples: @Command([MailComposeMemo]) 564
Language cross-reference . . . . . . . . 558 MailForward @Command . . . . . . . . . 564
Contents xxv
ObjectOpen @Command. . . . . . . . . . 577 Usage . . . . . . . . . . . . . . . 585
Syntax . . . . . . . . . . . . . . . 577 Examples: RefreshFrame command . . . . . 585
Usage . . . . . . . . . . . . . . . 577 RefreshHideFormulas @Command . . . . . . 586
Language cross-reference . . . . . . . . 577 Syntax . . . . . . . . . . . . . . . 586
ObjectProperties @Command . . . . . . . . 578 Usage . . . . . . . . . . . . . . . 586
Syntax . . . . . . . . . . . . . . . 578 Language cross-reference . . . . . . . . 586
Usage . . . . . . . . . . . . . . . 578 RefreshParentNote @Command . . . . . . . 586
Language cross-reference . . . . . . . . 578 Syntax . . . . . . . . . . . . . . . 586
OpenCalendar @Command . . . . . . . . . 578 Usage . . . . . . . . . . . . . . . 586
Syntax . . . . . . . . . . . . . . . 578 Language cross-reference . . . . . . . . 586
Parameter . . . . . . . . . . . . . 578 Examples: @Command([RefreshParentNote]) 586
Usage . . . . . . . . . . . . . . . 578 RefreshWindow @Command . . . . . . . . 586
Language cross-reference . . . . . . . . 578 Syntax . . . . . . . . . . . . . . . 586
OpenDocument @Command . . . . . . . . 578 Usage . . . . . . . . . . . . . . . 587
Syntax . . . . . . . . . . . . . . . 578 Language cross-reference . . . . . . . . 587
Parameters . . . . . . . . . . . . . 578 ReloadWindow @Command . . . . . . . . 587
Usage . . . . . . . . . . . . . . . 579 Syntax . . . . . . . . . . . . . . . 587
Language cross-reference . . . . . . . . 579 Usage . . . . . . . . . . . . . . . 587
Examples: OpenDocument . . . . . . . . 579 Language cross-reference . . . . . . . . 587
OpenFrameset @Command . . . . . . . . . 580 RemoteDebugLotusScript @Command . . . . . 587
Syntax . . . . . . . . . . . . . . . 580 Syntax . . . . . . . . . . . . . . 587
Parameters . . . . . . . . . . . . . 580 Usage . . . . . . . . . . . . . . . 587
Usage . . . . . . . . . . . . . . . 580 RemoveFromFolder @Command . . . . . . . 587
Language cross-reference . . . . . . . . 580 Syntax . . . . . . . . . . . . . . . 587
Examples: @Command([OpenFrameset]) . . . 580 Usage . . . . . . . . . . . . . . . 588
OpenHelpDocument @Command. . . . . . . 580 Language cross-reference . . . . . . . . 588
Syntax . . . . . . . . . . . . . . . 580 RenameDatabase @Command . . . . . . . . 588
Parameters . . . . . . . . . . . . . 581 Syntax . . . . . . . . . . . . . . . 588
Usage . . . . . . . . . . . . . . . 581 Parameters . . . . . . . . . . . . . 588
Examples: @Command([OpenHelpDocument]) 581 Usage . . . . . . . . . . . . . . . 588
OpenNavigator @Command . . . . . . . . 582 Language cross-reference . . . . . . . . 588
Syntax . . . . . . . . . . . . . . . 582 Examples: RenameDatabase . . . . . . . 589
Parameters . . . . . . . . . . . . . 582 Replicator @Command . . . . . . . . . . 589
Usage . . . . . . . . . . . . . . . 582 Syntax . . . . . . . . . . . . . . . 589
Language cross-reference . . . . . . . . 582 Usage . . . . . . . . . . . . . . . 589
OpenPage @Command . . . . . . . . . . 582 ReplicatorReplicateHigh @Command . . . . . 589
Syntax . . . . . . . . . . . . . . . 582 Syntax . . . . . . . . . . . . . . . 589
Parameters . . . . . . . . . . . . . 582 Usage . . . . . . . . . . . . . . . 589
Usage . . . . . . . . . . . . . . . 583 ReplicatorReplicateNext @Command . . . . . 589
Language cross-reference . . . . . . . . 583 Syntax . . . . . . . . . . . . . . . 589
OpenView @Command . . . . . . . . . . 583 Usage . . . . . . . . . . . . . . . 589
Syntax . . . . . . . . . . . . . . . 583 ReplicatorReplicateSelected @Command . . . . 590
Parameters . . . . . . . . . . . . . 583 Syntax . . . . . . . . . . . . . . . 590
Usage . . . . . . . . . . . . . . . 583 Usage . . . . . . . . . . . . . . . 590
Language cross-reference . . . . . . . . 583 ReplicatorReplicateWithServer @Command . . . 590
Examples: OpenView . . . . . . . . . . 584 Syntax . . . . . . . . . . . . . . . 590
PasteBitmapAsBackground @Command . . . . 584 Usage . . . . . . . . . . . . . . . 590
Syntax . . . . . . . . . . . . . . . 584 Language cross-reference . . . . . . . . 590
Usage . . . . . . . . . . . . . . . 584 ReplicatorSendMail @Command . . . . . . . 590
PasteBitmapAsObject @Command . . . . . . 584 Syntax . . . . . . . . . . . . . . . 590
Syntax . . . . . . . . . . . . . . . 584 Usage . . . . . . . . . . . . . . . 590
Usage . . . . . . . . . . . . . . . 584 ReplicatorSendReceiveMail @Command . . . . 590
PictureProperties @Command . . . . . . . . 584 Syntax . . . . . . . . . . . . . . . 591
Syntax . . . . . . . . . . . . . . . 584 Usage . . . . . . . . . . . . . . . 591
Usage . . . . . . . . . . . . . . . 584 ReplicatorStart @Command. . . . . . . . . 591
PublishDatabase @Command . . . . . . . . 584 Syntax . . . . . . . . . . . . . . . 591
Syntax . . . . . . . . . . . . . . . 585 Usage . . . . . . . . . . . . . . . 591
Usage . . . . . . . . . . . . . . . 585 Language cross-reference . . . . . . . . 591
RefreshFrame @Command . . . . . . . . . 585 ReplicatorStop @Command . . . . . . . . . 591
Syntax . . . . . . . . . . . . . . . 585 Syntax . . . . . . . . . . . . . . . 591
Parameters . . . . . . . . . . . . . 585 Usage . . . . . . . . . . . . . . . 591
Contents xxvii
TextNumbers @Command . . . . . . . . . 604 Usage . . . . . . . . . . . . . . . 610
Syntax . . . . . . . . . . . . . . . 604 Language cross-reference . . . . . . . . 610
Parameters . . . . . . . . . . . . . 604 ToolsCategorize @Command . . . . . . . . 610
Usage . . . . . . . . . . . . . . . 604 Syntax . . . . . . . . . . . . . . . 610
TextOutdent @Command . . . . . . . . . 604 Parameters . . . . . . . . . . . . . 610
Syntax . . . . . . . . . . . . . . . 604 Usage . . . . . . . . . . . . . . . 611
Usage . . . . . . . . . . . . . . . 604 Language cross-reference . . . . . . . . 611
Language cross-reference . . . . . . . . 604 Examples: ToolsCategorize . . . . . . . . 611
TextParagraph @Command . . . . . . . . . 604 ToolsHangUp @Command . . . . . . . . . 611
Syntax . . . . . . . . . . . . . . . 604 Syntax . . . . . . . . . . . . . . . 611
Usage . . . . . . . . . . . . . . . 605 Usage . . . . . . . . . . . . . . . 611
Language cross-reference . . . . . . . . 605 ToolsMarkAllRead @Command . . . . . . . 611
TextParagraphStyles @Command . . . . . . . 605 Syntax . . . . . . . . . . . . . . . 611
Syntax . . . . . . . . . . . . . . . 605 Usage . . . . . . . . . . . . . . . 611
Usage . . . . . . . . . . . . . . . 605 ToolsMarkAllUnread @Command . . . . . . 612
Language cross-reference . . . . . . . . 605 Syntax . . . . . . . . . . . . . . . 612
TextPermanentPen @Command . . . . . . . 605 Usage . . . . . . . . . . . . . . . 612
Syntax . . . . . . . . . . . . . . . 605 ToolsMarkSelectedRead @Command. . . . . . 612
Parameters . . . . . . . . . . . . . 605 Syntax . . . . . . . . . . . . . . . 612
Usage . . . . . . . . . . . . . . . 605 Usage . . . . . . . . . . . . . . . 612
Language cross-reference . . . . . . . . 606 ToolsMarkSelectedUnread @Command . . . . . 612
TextReduceFont @Command . . . . . . . . 606 Syntax . . . . . . . . . . . . . . . 612
Syntax . . . . . . . . . . . . . . . 606 Usage . . . . . . . . . . . . . . . 612
Usage . . . . . . . . . . . . . . . 606 ToolsRefreshAllDocs @Command . . . . . . . 613
Language cross-reference . . . . . . . . 606 Syntax . . . . . . . . . . . . . . . 613
TextSetFontColor @Command . . . . . . . . 606 Usage . . . . . . . . . . . . . . . 613
Syntax . . . . . . . . . . . . . . . 606 Language cross-reference . . . . . . . . 613
Parameters . . . . . . . . . . . . . 606 ToolsRefreshSelectedDocs @Command . . . . . 613
Usage . . . . . . . . . . . . . . . 607 Syntax . . . . . . . . . . . . . . . 613
Language cross-reference . . . . . . . . 607 Usage . . . . . . . . . . . . . . . 613
Examples: TextSetFontColor . . . . . . . 607 ToolsReplicate @Command . . . . . . . . . 613
TextSetFontFace @Command . . . . . . . . 607 Syntax . . . . . . . . . . . . . . . 613
Syntax . . . . . . . . . . . . . . . 607 Parameters . . . . . . . . . . . . . 613
Parameters . . . . . . . . . . . . . 607 Usage . . . . . . . . . . . . . . . 613
Usage . . . . . . . . . . . . . . . 607 Language cross-reference . . . . . . . . 614
Language cross-reference . . . . . . . . 607 ToolsRunBackgroundMacros @Command . . . . 614
Examples: TextSetFontFace . . . . . . . . 608 Syntax . . . . . . . . . . . . . . . 614
TextSetFontSize @Command . . . . . . . . 608 Usage . . . . . . . . . . . . . . . 614
Syntax . . . . . . . . . . . . . . . 608 ToolsRunMacro @Command . . . . . . . . 614
Parameters . . . . . . . . . . . . . 608 Syntax . . . . . . . . . . . . . . . 614
Usage . . . . . . . . . . . . . . . 608 Parameters . . . . . . . . . . . . . 614
Language cross-reference . . . . . . . . 608 Usage . . . . . . . . . . . . . . . 614
Examples: TextSetFontSize . . . . . . . . 608 Language cross-reference . . . . . . . . 614
TextSpacingDouble @Command . . . . . . . 608 Example: ToolsRunMacro . . . . . . . . 615
Syntax . . . . . . . . . . . . . . . 608 ToolsScanUnreadChoose @Command . . . . . 615
Usage . . . . . . . . . . . . . . . 609 Syntax . . . . . . . . . . . . . . . 615
Language cross-reference . . . . . . . . 609 Usage . . . . . . . . . . . . . . . 615
TextSpacingOneAndAHalf @Command . . . . . 609 ToolsScanUnreadPreferred @Command . . . . . 615
Syntax . . . . . . . . . . . . . . . 609 Syntax . . . . . . . . . . . . . . . 615
Usage . . . . . . . . . . . . . . . 609 Usage . . . . . . . . . . . . . . . 615
Language cross-reference . . . . . . . . 609 ToolsScanUnreadSelected @Command . . . . . 615
TextSpacingSingle @Command . . . . . . . 609 Syntax . . . . . . . . . . . . . . . 615
Syntax . . . . . . . . . . . . . . . 609 Usage . . . . . . . . . . . . . . . 615
Usage . . . . . . . . . . . . . . . 609 ToolsSetupLocation @Command . . . . . . . 615
Language cross-reference . . . . . . . . 609 Syntax . . . . . . . . . . . . . . . 616
TextUnderline @Command . . . . . . . . . 609 Usage . . . . . . . . . . . . . . . 616
Syntax . . . . . . . . . . . . . . . 610 ToolsSetupMail @Command . . . . . . . . 616
Usage . . . . . . . . . . . . . . . 610 Syntax . . . . . . . . . . . . . . . 616
Language cross-reference . . . . . . . . 610 Usage . . . . . . . . . . . . . . . 616
ToolsCall @Command . . . . . . . . . . 610 ToolsSetupPorts @Command . . . . . . . . 616
Syntax . . . . . . . . . . . . . . . 610 Syntax . . . . . . . . . . . . . . . 616
Contents xxix
Syntax . . . . . . . . . . . . . . . 628 Usage . . . . . . . . . . . . . . . 630
Usage . . . . . . . . . . . . . . . 628 WindowMinimize @Command . . . . . . . 630
ViewShowOnlyUnread @Command . . . . . . 628 Syntax . . . . . . . . . . . . . . . 630
Syntax . . . . . . . . . . . . . . . 628 Usage . . . . . . . . . . . . . . . 630
Usage . . . . . . . . . . . . . . . 628 WindowMinimizeAll @Command . . . . . . 631
ViewShowPageBreaks @Command . . . . . . 628 Syntax . . . . . . . . . . . . . . . 631
Syntax . . . . . . . . . . . . . . . 628 Usage . . . . . . . . . . . . . . . 631
Usage . . . . . . . . . . . . . . . 628 WindowNext @Command . . . . . . . . . 631
ViewShowRuler @Command . . . . . . . . 628 Syntax . . . . . . . . . . . . . . . 631
Syntax . . . . . . . . . . . . . . . 628 Usage . . . . . . . . . . . . . . . 631
Usage . . . . . . . . . . . . . . . 628 WindowRestore @Command . . . . . . . . 631
ViewShowSearchBar @Command . . . . . . . 628 Syntax . . . . . . . . . . . . . . . 631
Syntax . . . . . . . . . . . . . . . 629 Usage . . . . . . . . . . . . . . . 631
Parameters . . . . . . . . . . . . . 629 WindowTile @Command . . . . . . . . . 631
Usage . . . . . . . . . . . . . . . 629 Syntax . . . . . . . . . . . . . . . 631
ViewShowServerNames @Command . . . . . 629 Usage . . . . . . . . . . . . . . . 632
Syntax . . . . . . . . . . . . . . . 629 WindowWorkspace @Command . . . . . . . 632
Usage . . . . . . . . . . . . . . . 629 Syntax . . . . . . . . . . . . . . . 632
ViewShowUnread @Command . . . . . . . 629 Usage . . . . . . . . . . . . . . . 632
Syntax . . . . . . . . . . . . . . . 629 WorkspaceProperties @Command . . . . . . 632
Usage . . . . . . . . . . . . . . . 629 Syntax . . . . . . . . . . . . . . . 632
ViewSwitchForm @Command . . . . . . . . 629 Usage . . . . . . . . . . . . . . . 632
Syntax . . . . . . . . . . . . . . . 629 WorkspaceStackReplicaIcons @Command . . . . 632
Parameters . . . . . . . . . . . . . 629 Syntax . . . . . . . . . . . . . . . 632
Usage . . . . . . . . . . . . . . . 629 Usage . . . . . . . . . . . . . . . 632
WindowCascade @Command . . . . . . . . 630 ZoomPreview @Command . . . . . . . . . 632
Syntax . . . . . . . . . . . . . . . 630 Syntax . . . . . . . . . . . . . . . 632
Usage . . . . . . . . . . . . . . . 630 Parameters . . . . . . . . . . . . . 632
WindowMaximize @Command . . . . . . . 630 Usage . . . . . . . . . . . . . . . 633
Syntax . . . . . . . . . . . . . . . 630
Usage . . . . . . . . . . . . . . . 630 Index . . . . . . . . . . . . . . . 635
WindowMaximizeAll @Command . . . . . . 630
Syntax . . . . . . . . . . . . . . . 630
Event descriptions
Event sequencing
Lotus Domino Designer provides a programming interface to development environments that support
COM and OLE. Lotus Domino Designer provides a programming interface for Java applications and
applets. Java applications and applets can operate locally by accessing installed Domino software or
remotely by connecting to a Domino server using CORBA with IIOP protocols.
The Overview - applications and databases and database management sections of the Application
Development with Domino Designer book provide guidelines, templates, and examples for the common
cases where you use code. For these cases, you do not have to learn how to program. Beyond these cases,
refer to this manual for complete guidelines and reference material for programming in Lotus Domino
Designer.
Where you have a choice among programming interfaces, consider these guidelines:
v Formulas are expressions that have program-like attributes. For example, you can assign values to
variables and use a limited control logic. The formula language interface to Lotus Domino Designer is
through calls to @functions and @commands.
In general, formulas are best used for working within the object that the user is currently processing,
for example, to return a default value to a field or determine selection criteria for a view. Additionally,
formulas provide better performance in some situations and may be more convenient for simple
applications. You can also execute looping logic using functions such as @For, @While, and @DoWhile.
1
Area. Scripts may also be attached to specific events such as onClick, or to objects such as buttons.
JavaScript may not be written in an agent. Lotus Domino Designer oversees the compilation and
loading of user scripts, but does not store JavaScript in compiled form. In LotusScript Web agents, you
can use Print statements to output HTML to the browser, including script tags. For example,
Print<script>function changeLocation(){...}</script>.
JavaScript is best used for Web applications, or when a single application will be used in both the
Lotus Notes(R) and Web environments. Version 1.4 of the JavaScript language is supported.
v LotusScript is a full object-oriented programming language. Its interface to Lotus Domino is through
predefined classes. Lotus Domino oversees the compilation and loading of user code, and
automatically includes the Domino class definitions.
LotusScript is best used where the programming logic is not simple. It excels in accessing stored
databases (back-end) and provides some capabilities that formulas do not, such as the ability to
manipulate a database access control list (ACL). LotusScript is limited in its UI (front-end) capabilities.
v Java is a full object-oriented programming language. Its interface to Lotus Domino is through
predefined classes. It is comparable to LotusScript in agents but cannot be attached to events in the
Domino UI. Lotus Domino oversees the compilation and loading of user code for agents; the code can
be written natively or imported.
Java can be used in agents. Java applications and applets, written and compiled outside of Lotus
Domino, can access Lotus Domino through the class interface.
Toolbars
Toolbars provide a quick way to trigger commonly performed tasks, such as printing a document or
refreshing a view. A Toolbar button works by executing a formula when you select it from a toolbar. You
can customize the toolbars provided with Domino Designer or create your own.
For more details on editing existing toolbars, see Toolbars: smart shortcuts in Lotus Notes Help.
Tip: You can also right-click a toolbar and select Toolbar Preferences from the pop-up menu.
2. Select the Toolbars tab.
3. To either:
v Edit an existing toolbar, select it from the Available Toolbars list.
v Create a new toolbar, click New Toolbar, enter a name in the text box and press ENTER.
4. Select the Customize tab.
The name of the toolbar you are editing or creating displays in the Toolbar to modify field.
5. Add predefined Notes buttons to the toolbar by either:
v Dragging and dropping buttons from the Available Buttons list to the Toolbar Contents pane.
v Selecting a button (or buttons using the CNTRL key while selecting) and clicking Add to toolbar.
Tip: You can change the display of the Available Buttons list to list them alphabetically by clicking
Sort Buttons and selecting by Description.
6. To create and add a new button, click New and select Button from the drop-down list.
The Edit Toolbar Button dialog box displays.
7. Enter a name for the button in the Button Text field and enter a description of the task the button
performs in the Pop Up Help Text field.
This text appears when a user mouses over the button.
8. Add the formula that this button triggers in the Formula box.
Click the Fields & Functions button to see a list of the fields, @functions, and @commands available
for you to reference in the formula.
Click the Formula Window button if you want a larger window in which to write and edit your
formula.
9. Click the Change Icon button and select an image from the Insert Image Resource dialog box.
Tip: Supply an icon so that the button is visible to users. The default display style, which you can
change on the Basics tab of the Toolbar Preferences dialog box, is Icon only. If this is selected, only
icons display on the toolbar; button text does not.
10. Click Save Toolbar, then click OK to close the Toolbar Preferences dialog box.
Toolbars are associated with each users workspace; they are not associated with databases and are not
shared among users. Toolbars are also specific to each client. A toolbar you customize in Designer does
not display in the Notes client.
Examples: Toolbars
1. This toolbar button formula opens the names.nsf database on the doc server to the People view:
@Command([FileOpenDatabase]; "DOC" : "NAMES.NSF"; "People")
2. This toolbar button formula presents the user with the list of databases in a database catalog, and
opens the database that the user selects. The first @DbColumn puts a list of the values in column 4 of
the Databases by _Replica ID view in the temporary variable titles. The second @DbColumn puts a
list of the values in column 2 of the Databases by _Replica ID view in the temporary variable servers.
The third @DbColumn puts a list of the values in column 3 of the Databases by _Replica ID view in
the temporary variable databases. The temporary variable list combines titles, servers, and databases
Replication formulas
A replication formula selects the documents that are pulled into the current database during replication.
A replication formula must end with a SELECT statement. If the last statement in the formula is a logical
expression, Domino turns it into a SELECT statement by inserting the reserved word SELECT.
A replication formula runs on the server or workstation containing the formulas database.
Agents
An agent is a user procedure that you can trigger through a number of mechanisms. An agent runs on:
v The users workstation if the agents trigger is Action menu selection, Agent list selection, or When
documents are pasted.
v The server or workstation containing the agent if the agents trigger is Before new mail arrives,
After new mail has arrived, or After documents are created or modified, or any of the On
schedule options.
You can code agents in the formula language, LotusScript, and Java, and you can use Domino-supplied
agents. Before writing your own agent, see if a Domino-supplied agent will do the job.
Formula-based agents run iteratively on the documents in the database, unless you select None in the
agents target option. You can also apply search criteria through the agent interface to specify which
documents in the database are to be processed. A SELECT statement in the formula further limits the
search. If you do not include a SELECT statement in the formula, Domino Designer appends a SELECT
@All statement. Except for SELECT @All, a SELECT statement must be the first statement in the
formula to be effective.
@Commands are only allowed in agents that specify None in the target option.
Examples: Agents
1. This LotusScript code writes a value to the Category field based on the value of the TotalSales field of
each document in the database. Compare with Examples 2 and 3, which use Java and formula
solutions. The script example requires more lines of code than the formula solution but includes the
algorithm for finding the documents being processed.
Sub Initialize
Dim session As New NotesSession
Dim db As NotesDatabase
Dim dc As NotesDocumentCollection
Dim doc As NotesDocument
Set db = session.CurrentDatabase
Set dc = db.AllDocuments
Set doc = dc.GetFirstDocument
While Not(doc Is Nothing)
category = doc.Category
totalSales = doc.TotalSales
Select Case totalSales(0)
Case Is >= 200000 : category(0) = "Above Quota"
Case Is >= 100000 : category(0) = "OK"
Case Else : category(0) = "Below Quota"
End Select
doc.Category = category
Call doc.Save(True, False)
Set doc = dc.GetNextDocument(doc)
Wend
End Sub
2. This Java agent writes a value to the Category field based on the value of the TotalSales field of each
document in the database. Compare with Examples 1 and 3, which use LotusScript and formula
solutions. As with LotusScript, the Java code includes the algorithm for finding the documents being
processed.
import lotus.domino.*;
public class JavaAgent extends AgentBase {
public void NotesMain() {
try {
Session session = getSession();
AgentContext agentContext = session.getAgentContext();
// (Your code goes here)
Database db = agentContext.getCurrentDatabase();
DocumentCollection dc = db.getAllDocuments();
Document doc = dc.getFirstDocument();
while (doc != null) {
double totalSales = doc.getItemValueDouble("TotalSales");
if (totalSales >= 200000)
doc.replaceItemValue("Category", "Above quota");
else if (totalSales >= 100000)
doc.replaceItemValue("Category", "OK");
else
doc.replaceItemValue("Category", "Below quota");
doc.save(true, false);
doc = dc.getNextDocument();
}
} catch(Exception e) {
e.printStackTrace();
}
}
}
Actions
An action is a formula, LotusScript, JavaScript, or simple (no programming) procedure that you can
associate with a view, form, subform, or page. You can create a standard action, an action with
subactions, a shared action, or insert system actions that are supplied with Notes.
If you create a standard action, when you open the view or page, or open a document based on the form,
the action becomes available as a menu command under Actions and/or as a button on an action bar. If
you create an action with subactions, the parent action is not programmable but appears as a button with
You can insert the standard system actions, which include action buttons that perform basic functions
such as forwarding, editing, or sending a document. Additionally, you can create and insert a shared
action that you can reuse in several different design elements. This enables you to make any updates or
enhancements to the actions code in one place and it is automatically updated in all the elements that
use it.
You can conditionally suppress availability of an action on the menu or action bar with a Hide action if
formula is true formula. @Commands are not allowed in hide formulas.
Examples: Actions
1. This LotusScript action prints the name of each Domino database in the Domino data directory on the
computer running the script. The FirstDatabase and NextDatabase methods of NotesDbDirectory walk
through all the databases for the specified server where null defaults to the current computer.
Sub Click(Source As Button)
Dim directory As New NotesDbDirectory("")
Dim db As NotesDatabase
Set db = directory.GetFirstDatabase(DATABASE)
While Not(db Is Nothing)
Messagebox db.Title
Set db = directory.GetNextDatabase()
Wend
Messagebox "The End"
End Sub
2. This formula lists the names in the Address Book on the CORP1 server, lets the user select any
number of names, combines the selected names into a string using a comma and a space to separate
names, and inserts the string into the current field. This action works best when the user is in the
SendTo field of a mail database.
last := @Left(@DbColumn(""; "CORP1" : "NAMES.NSF"; "People"; 1); ",");
first := @RightBack(@DbColumn(""; "CORP1" : "NAMES.NSF"; "People"; 2); " ");
list := first + " " + last;
name := @Prompt([OKCANCELLISTMULT]; "Send To"; "Who are you sending this memo to?"; ""; list);
@Command([EditInsertText]; @Implode(name; ", "))
3. This formula is a Hide action if formula is true formula. The action becomes available on the form
menu or action bar only if the field OrderTotal is 100 or less. (If the user just entered a value for
Order_Total in the current document, a document refresh must occur before the new value is
effective.)
OrderTotal > 100
4. These scripts collectively force the user to use an action to place an existing document in Edit mode.
The action script places the current document in Edit mode. The Postopen and Querychangemode
event scripts prevent the user from changing to Edit mode through other means such as Actions -
Edit Document (CTRL+E).
(Globals) object, (Declarations) event
Dim allowEdit As Integer
(Form) object, Postopen event
Sub Postopen(Source As Notesuidocument)
Let document pass if new or not in EditMode
Otherwise if existing document is in EditMode
Set allowEdit so Querymodechange doesnt reprocess
Turn EditMode off so document opens in Read mode
Hotspots
In form design, subform design, page design, navigator design, layout region design, and rich text fields,
you can create hotspots. A hotspot activates when the user selects it and can be any of several types:
v A link hotspot jumps to another object. As the designer, you supply the link.
v A text pop-up displays text. As the designer, you supply literal text.
v A button performs an action. As the designer, you supply a simple action, or formula, LotusScript, or
JavaScript code.
v A formula pop-up displays text based the result of a formula. As the designer, you supply a formula.
v An action hotspot performs an action. As the designer, you supply a simple action, or formula,
LotusScript, or JavaScript code.
Buttons and action hotspots are the same except that a button appears as a button and an action hotspot
appears as highlighted text.
(Click event)
Sub Click(Source As Button)
Dim session As New NotesSession
Dim db As NotesDatabase
Dim doc As NotesDocument
Set db = session.CurrentDatabase
Set doc = New NotesDocument(db)
yesno = Messagebox _
("Do you want to attend?", MB_YESNO+MB_ICONQUESTION)
If yesno = IDYES Then rsvp = "Yes" Else rsvp = "No"
Call doc.AppendItemValue("Subject", "RSVP")
Call doc.AppendItemValue("Body", rsvp)
Call doc.Send(True, session.UserName)
End Sub
5. This formula button or action hotspot is useful in a mail message to a group of persons. When the
recipient clicks the hotspot, the formula sends a mail message indicating Yes or No for the RSVP.
For testing, the name of the current user is used -- in practice, you can use your name. Compare with
the previous example, which uses a LotusScript solution.
yesno := @Prompt([YESNO]; "RSVP"; "Do you want to attend?");
rsvp := @If(yesno; "Yes"; "No");
@MailSend(@UserName; ""; ""; "RSVP"; ""; rsvp; "")
6. This LotusScript button or action hotspot displays the sum of all OrderTotal fields in a database for
one day. Each record in the database has OrderNumber, Date, and OrderTotal fields. The script finds
all the documents in the database, then uses a loop and a comparison of dates to limit processing to
todays documents. For each document, the script adds the OrderTotal to a dailyTotal variable.
Sub Click(Source As Button)
Dim session As New NotesSession
Dim db As NotesDatabase
Dim dc As NotesDocumentCollection
Set db = session.CurrentDatabase
Set dc = db.AllDocuments
Form formulas
A form formula determines which forms are used for composing and displaying documents under
different conditions.
A form formula is optional. Lotus Domino Designer selects a form in the following preference order:
1. Form stored in the document.
2. Form specified in the form formula.
3. Form with which the document was created.
4. Default form for the database.
A form formula must evaluate to the name of a form. To enter a form formula:
1. Open the view in Lotus Domino Designer.
2. Select the Form Formula object on the Objects tab.
3. Enter a formula in the Script area.
To avoid this problem, add the following line to the form formula.
@If(@IsNewDoc; @Return(Form); "")
Selection formulas
A selection formula selects the documents that appear in a view.
A selection formula must end with a SELECT statement. If the last statement in the formula is a logical
expression, Lotus Domino Designer turns it into a SELECT statement by prepending the reserved word
SELECT.
Column formulas
A column formula determines what is displayed in a column of a view. It must evaluate to a text string.
A section access formula must evaluate to a name, role, or a list of names or roles.
For details, see the topic, Using a hide-when formula in a column in the Application Development with
Domino Designer book.
Each of these formulas must evaluate to a text value. @Commands are not allowed.
Image formulas
Formulas can be used to specify the name of an outline image, the background image in a view, the
background image in an embedded outline, the twisties image in a column, and the twisties image in an
embedded outline.
Events
You can write scripts and formulas to handle events that occur during processing as shown in the Event
descriptions topic. For information on the sequence of events based on certain tasks, see the table Event
sequencing.
In the Programmers pane, you access objects and events through the Objects tab in the Info List.
Database, view, form, button, navigator, and field events run on the users workstation.
Examples: Events
1. This LotusScript event executes when a database opens. It opens a particular view depending on the
value of the OrgUnit1 part of the users name.
Sub Postopen(Source As Notesuidatabase)
Dim session As New NotesSession
Dim userName As NotesName
Set userName = session.CreateName(session.UserName)
Select Case userName.OrgUnit1
Case "Marketing"
Call Source.OpenView("Marketing")
Case "Engineering"
Call Source.OpenView("Engineering")
Case Else
Call Source.OpenView("General")
End Select
End Sub
2. This LotusScript event executes before the Engineering view opens. If the OrgUnit1 part of the users
name is not Engineering, the script displays a message and sets Continue to False so that the view
does not open.
Sub Queryopen(Source As Notesuiview, Continue As Variant)
Dim session As New NotesSession
Dim userName As NotesName
Set userName = session.CreateName("session.UserName")
If userName.OrgUnit1 <> "Engineering" Then
Continue = False
Messagebox _
"This view is reserved for engineering",, _
"No admittance"
End If
End Sub
3. This LotusScript event executes when the user opens a document. The document goes into Edit mode
even if the user doesnt open it that way, the ruler opens, and all sections expand.
Sub Postopen(Source As Notesuidocument)
source.EditMode = True
source.Ruler = True
Call source.ExpandAllSections
End Sub
4. This JavaScript button script alters the value of one of the fields on the associated form. In this
example, a document can be assigned a priority rating from 1 to 10, with 1 being the highest priority.
The documents priority rating is held in a field called Priority on the form. The button Increase
Priority allows users to increase the priority without the need to edit the field directly. When the
button is clicked, the Priority fields value is decreased by 1, assigning it a higher priority rating. The
script will not allow a priority of less than 1 to be assigned.
A default value formula must evaluate to a value suitable for storage in the current field.
An input translation formula should return a value of the same data type as the current field. For
example, if the field is a Text field, the input translation formula should return a text string value. If the
field is a Date/Time field, the input translation formula should return a date/time value.
A computed field formula must evaluate to a value suitable for storage in the current field.
A keyword field formula must evaluate to a value or list of values suitable for storage in the current
field.
Event descriptions
Simple action, Formula, LotusScript, JavaScript, and Java code executes in response to the occurrence of
events in the following objects: actions, action hotspots, agents, hotspot buttons, databases, fields, folders,
forms, formula pop-ups, outlines, pages, script libraries, subforms, and views.
You code the same event twice; once for the Notes client platform and once for the Web platform.
Note: The separate handling of Notes client and Web browser events is new for Release 6. See
Compatibility issues below. The one exception to the coding same event twice rule is with actions and
shared actions. If you are designing in Release 6 and running in Release 5, you must code two separate
actions, one for each platform. Use the hide-when formulas to hide an action from Notes or Web
platforms.
Web events can be coded only in JavaScript. You can specify the same JavaScript code for both a Web
event and its corresponding Notes client event.
The following table lists the events that can be handled using the formula language, LotusScript,
JavaScript and Java code in the Notes client and Web browser environments. Non-programming handlers
such as simple actions are also listed. For information on sequencing of events, see the table Event
sequencing. For information on the user interface, see Exploring the Programmers pane and Using
the Objects tab.
Java
LotusScript
Imported Java
Simple action(s)
Click Client Formula Action Object is selected
Navigator object
Picture Hotspot
Click Client Formula Formula Popup Object is selected
Column Value Client Field Folder column Object is loaded
Simple Function
Action Hotspot
Agent
Button
Database Script
Field
Folder
Form
Globals
Navigator object
Page
Picture Hotspot
LotusScript Script
Library
Subform
View
Default Value Client Formula Field Document is created
Web
Document Selection Client Simple Search Agent Object is loaded
Entering Client LotusScript Field Object is selected
Note: Preferred is
onFocus
Exiting Client LotusScript Field Object is deselected
Note: Preferred is
onBlur
Form Formula Client Formula Folder Object is loaded
Web View
Frame - Client Client Formula Outline Entry Object is loaded
Web
HelpRequest Client Formula Folder Help is selected
View
Hide When Client Formula Outline Entry Object is loaded
Web
HTML Attributes Web Formula Field Form is loaded
HTML Body Web Formula Form Form is loaded
Attributes
Page
Action Hotspot
Agent
Button
Database Script
Field
Folder
Form
Globals
Navigator object
Page
Picture Hotspot
LotusScript Script
Library
Subform
View
Input Enabled Client Formula Field Form is loaded
Input Translation Client Formula Field Document is saved
Web
Input Validation Client Formula Field After Input Translation
Web
InViewEdit Client LotusScript Folder View entry is edited: at query,
Note: New with validation, and save
Release 6 View
JavaAgent Client Java Agent Object is loaded
Javascript Library ClientWeb JavaScript Script Library Object is loaded
Java class name Client Java Script Library Object is loaded
JS Header Client JavaScript Form Object is loaded
Web Page
Subform
Label Client Formula Outline Entry Object is loaded
Action Hotspot
Button
Field
onChange Client JavaScript Field Contents of object change
Note: New with
Release 6 LotusScript
onChange Web JavaScript Field Contents of object change
onClick Web JavaScript Action Object is selected
Action Hotspot
Button
Field
Form
Page
Picture
onDblClick Web JavaScript Action Double-click occurs on object
Action Hotspot
Button
Field
Form
Page
Picture
onFocus Client LotusScript Field Object is selected
Note: New for
LotusScript with JavaScript
Release 6
onFocus Web JavaScript Action Object is selected
Action Hotspot
Button
Field
LotusScript Page
JavaScript
onHelp Web JavaScript Action Help is selected
Action Hotspot
Button
Form
Page
Picture
onKeyDown Web JavaScript Action Any key is pressed
Action Hotspot
Button
Field
Form
Page
Picture
onKeyPress Web JavaScript Action An alphanumeric key is pressed
Action Hotspot
Button
Field
Form
Page
Picture
onKeyUp Web JavaScript Action Any key is released
Action Hotspot
Button
Field
Form
Page
Picture
onLoad Client JavaScript Form Object is loaded
Note: New for
Formula and Formula Page
LotusScript with
Release 6 LotusScript
Page
onMouseDown Web JavaScript Action Object is selected with either the
right or left mouse button
Action Hotspot
Button
Field
Form
Page
Picture
onMouseMove Web JavaScript Action Mouse is moved over object
Action Hotspot
Button
Field
Form
Page
Picture
onMouseOut Web JavaScript Action Mouse is moved out of object
Action Hotspot
Button
Field
Form
Page
Picture
onMouseOver Web JavaScript Action Mouse is moved into object
Action Hotspot
Button
Field
Form
Page
Picture
Button
Field
Form
Page
Picture
onReset Web JavaScript Form Object is reset
onSelect Web JavaScript Field Contents of object are selected
OnSubmit Client Formula Form Before object is saved
Note: New for
Formula and JavaScript Page
LotusScript with
Release 6 LotusScript
Page
Options Client LotusScript Action Object is loaded
Action Hotspot
Agent
Button
Database Script
Field
Folder
Form
Globals
Navigator object
Page
Picture Hotspot
LotusScript Script
Library
Subform
View
View
PostEntryResize Client Formula Folder After a resize operation in a
Note: New with calendar folder or view
Release 6 LotusScript View
PostModeChange Client Formula Form After object is changed to Read or
Edit mode
LotusScript Subform
JavaScript
PostOpen Client Formula Database Script After object is opened
Note: Preferred is
onLoad for Form LotusScript Folder
and Page
Form
Page
Subform
View
PostPaste Client Formula Folder After a paste operation
LotusScript View
PostRecalc Client Formula Form After object is refreshed (and
values are recalculated)
JavaScript Page
LotusScript Subform
PostSave Client Formula Form After object is saved
JavaScript Subform
LotusScript
PostSend Client Formula Form After object is sent
Note: New with
Release 6 JavaScript Subform
LotusScript
QueryAddToFolder Client Formula Folder Before a document is added to a
folder
LotusScript View
Page
Subform
View
QueryDocumentDeleteClient Formula Database Script Before a document is marked for
deletion
LotusScript
QueryDocumentUndelete
Client Formula Database Script Before a document is unmarked
for deletion
LotusScript
QueryDragDrop Client Formula Database Script Before a drag and drop operation
LotusScript Folder
View
QueryEntryResize Client Formula Folder Before a resize operation in a
Note: New with calendar folder or view
Release 6 LotusScript View
QueryModeChange Client Formula Form Before a document is changed to
Read or Edit mode
JavaScript Subform
LotusScript
QueryOpen Client Formula Form Before object is opened
JavaScript Page
LotusScript Subform
QueryOpen Client Formula Folder Before object is opened
LotusScript View
QueryOpenDocument Client Formula Folder Before a document is loaded
LotusScript View
QueryPaste Client Formula Folder Before a paste operation
LotusScript View
QueryRecalc Client Formula Form Before object is refreshed (and
Note: New with values are recalculated)
Release 6 JavaScript Page
LotusScript Subform
QueryRecalc Client Formula Folder Before object is refreshed (and
values are recalculated)
LotusScript View
QuerySave Client Formula Form Before object is saved
Note: Preferred is
onSubmit for Form LotusScript Subform
LotusScript
RegionDoubleClick Client Formula Folder Region in a calendar view or
folder is double-clicked
LotusScript View
Source Client Formula Outline Entry Object is loaded
Target Frame Client Formula Form Object is loaded
Web Page
Target Frame (single Client Formula Folder Object is loaded
click)
Web View
Target Frame Client Formula Folder Object is loaded
(double click)
Web View
Terminate Client LotusScript Action Object is unloaded
Action Hotspot
Agent
Button
Database Script
Field
Folder
Form
Globals
Navigator object
Page
Picture Hotspot
LotusScript Script
Library
Subform
View
Value Client Formula Field Computed field is calculated
Web
View Selection Client Formula Folder Object is loaded
Web Page
**WebQueryOpen and WebQuerySave must be a formula with either of the following @commands:
@Command([RunAgent];"agentname")
@Command([ToolsRunMacro];"agentname")
Compatibility issues
In Notes Release 5 certain JavaScript events occur on the Notes client as well as the Web browser. In
addition, Formula/LotusScript events that respond to the same user actions also occur on the Notes
client. For example, both the onBlur and Exiting events occur when the Notes client user exits a field.
Release 6 distinguishes between the application of events to the Notes client and Web browser. You code
one JavaScript or LotusScript event for the Notes client and a separate JavaScript event for the Web
browser. Those JavaScript events that occur on the Notes client in Release 5 allow LotusScript and in
some cases Formula in Release 6. The corresponding LotusScript-only events still occur, but their
continued use in Release 6 applications is discouraged.
In Notes Release 5, for example, if you code the onBlur event for FieldOne as follows:
with (window.document.forms[0]) {
if (FieldOne.value == "foo") {
FieldTwo.value = "bar"
}
}
FieldTwo is set to bar if FieldOne is foo when the user exits the field in either a Web browser or the
Notes client.
To duplicate this functionality in Release 6, you specify the code twice, once for the onBlur - Web event
and again for the onBlur - Client event, or specify the code under Common JavaScript.
If, in addition to coding onBlur, you code the Exiting event for FieldOne as follows:
Sub Exiting(Source As Field)
Dim w As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Set uidoc = w.CurrentDocument
If uidoc.FieldGetText("FieldOne") = "foo" Then
Call uidoc.FieldSetText("FieldThree", "bar")
End If
End Sub
FieldThree is also set to bar if FieldOne is foo when the user exits the field in the Notes client, but not
in a Web browser.
In Release 6, if backwards compatibility is not an issue, you should combine the code in the onFocus -
Client event and remove the Exiting event. You can code in JavaScript:
with (window.document.forms[0]) {
if (FieldOne.value == "foo") {
FieldTwo.value = "bar"
FieldThree.value = "bar"
}
}
Or LotusScript:
Sub Onblur(Source As Field)
Dim w As New NotesUIWorkspace
Dim uidoc As NotesUIDocument
Set uidoc = w.CurrentDocument
If uidoc.FieldGetText("FieldOne") = "foo" Then
Forward compatibility
Notes Release 5 applications running in the Release 6 Notes client behave the same. Those JavaScript
events that worked in the Notes client continue to work on both the Web and the client. The LotusScript
PostOpen, QueryClose, QuerySave, Entering, Exiting, and Click events continue to work.
When a Release 5 application is saved in Release 6 Domino Designer, JavaScript events are moved into
their corresponding Web and (where applicable) Client events. The LotusScript events remain. For
example, the onBlur event is moved into the onBlur - Web and onBlur - Client events, and the Exiting
event remains.
However, if backwards compatibility is not an issue, you are urged to revise the code in the following
cases:
v For the JavaScript events that run on both the Notes client and the Web, where you use conditional
code to modify the behavior for one environment or the other: instead use two routines, one for the
client and one for the Web.
v For the LotusScript events: move the code to the corresponding on client event.
Backwards compatibility
Release 6 applications running in the Release 5 Notes client behave the same as in the Release 6 client
except that events new to Release 6 do not work in R5. For example, onLoad - Client for LotusScript does
not work in Release 5.
If you recompile an Release 6 application in Release 5, JavaScript client events are lost and JavaScript
Web events are reinstated for both client and Web. For example, onLoad - Client for JavaScript disappears
if compiled in Release 5. JavaScript - Web does not disappear if compiled in Release 5 but now works for
both client and Web.
Therefore a caveat exists to the guidelines for forward compatibility. If you continue to design in both
Release 5 and Release 6, you should keep the LotusScript PostOpen, QueryClose, QuerySave, Entering,
and Exiting events, not use the LotusScript on events, and code the JavaScript events for both client and
Web (use Common JavaScript).
In Release 6 the onHelp - Web event is the same as the Release 5 onHelp event. The onHelp - Client
event, which supports Formula, LotusScript, and JavaScript, has the behavior of HelpRequest in Release
5. HelpRequest is gone from form design.
Event sequencing
The following table shows the sequencing of events during common Notes tasks.
PostModeChange
Terminate
Terminate (View)
QueryClose (Database)
Terminate (Database)
onUnload
Terminate (Fields)
Terminate (Form)
Globals Terminate
Globals Initialize
Initialize
JS Header
QueryOpen
Initialize (Fields)
PostOpen
onLoad
Deleting a document in a view QueryDocumentDelete (Database Script event)
Globals Initialize
Initialize (Form)
JS Header
QueryOpen
Initialize (Fields)
PostOpen
onLoad
Entering a field Entering
onFocus
Exiting a field onBlur
Exiting
onChange
Leaving a view QueryClose
Terminate
Globals Terminate
Initialize (View)
QueryOpen (View)
PostOpen (View)
Initialize (Database)
PostOpen (Database)
Opening a database [optional] Script Library Initialize
Initialize
PostOpen
Opening a view [optional] Script Library Initialize
Globals Initialize
Initialize
QueryOpen
PostOpen
Initialize
Terminate
onSubmit
PostSave
Undeleting a document in a view QueryDocumentUndelete (Database Script event)
For information about developing design elements, see Application Development with Domino Designer.
37
Interface element Purpose
Errors box Displays compile-time errors for LotusScript and Java.
Help button Launches Lotus Domino Designer 6 Help from the
Programmers pane. Located on the Reference tab. Same
as F1 or Help - Context Help.
Info list Contains the Objects and Reference tabs.
Objects tab Lists all of the objects and events available for
programming in the current context.
Paste button Pastes selected information into the Script area. CTRL+V
is a shortcut.
Paste full text check box If selected, pastes the syntax of an event, method, or
property from the Reference tab into the Script area when
you click the Paste button.
Reference list Allows you to see and select reference information.
Reference tab Lists reference information and syntax.
Run menu Enables you to select the desired programming
environment (Client or Web) and language (Formula,
Simple action(s), LotusScript, JavaScript, Imported Java,
and Java). It displays only the environments and
languages available for the current design state. You can
choose to use the same JavaScript for both environments
by selecting the option Common JavaScript.
Note: Using the Run menu to select a programming
environment is new with Release 6.
Script area Provides a space to write and compile all recognized
programming languages.
Title bar Displays the title of the design element that the
programming language is attached to. Double-click here to
maximize or minimize the Programmers pane (does not
change for Agents).
When Imported Java is selected from the Run menu, the Programmers pane does not include the Edit
Project, New Class, Export, and Compile buttons. The Programmers pane includes the following features
for Imported Java.
Press CTRL+0 (zero) to access the Objects tab from the Script area using the keyboard. In the Java
programming environment, CTRL+0 accesses the Classes tab.
Note: When you click from one object to another of the same type, the event selected for the first object
is also selected for the second object. For example, if you click a field in the Work pane and select the
Default Value event, then click a different field, the event selected for the second field is Default Value.
Clicking objects of different types in the Work pane moves the Objects tab pointer to the first coded event
for each object.
JavaScript
LotusScript
Simple Action(s)
System Command(s)
Pasting information from the Reference tab into the Script area
1. Place the cursor where you want the item to appear in the Script area.
2. Click the item you want to paste, then click Paste.
Keys Selects
CTRL+1 The first reference component
CTRL+2 The second reference component
CTRL+3 The third reference component
CTRL+4 The fourth reference component
CTRL+5 The fifth reference component
CTRL+6 The sixth reference component
To open the Properties box, click inside the Script area and then choose Edit - Properties.
To set the text properties for a specific programming language, if available, click Script/Java, Formulas, or
Simple actions under Text formatting for all. Select the desired text font, size, and color from the lists
provided.
Select different colors as desired to represent identifiers, keywords, comments, errors, and constants using
the lists on the right side of the Properties box.
LotusScript code is automatically indented. To disable this property check the Auto-Indent LotusScript
box.
To specify whether line wrapping is enabled or disabled when writing formula language, check the
Auto-Wrap Formulas box. The default setting is enabled.
Use the Automatically add Option Declare box to add the Option Declare statement to new LotusScript
objects. The default setting is disabled.
Moving the insertion point while editing text in the Script area
The table below lists keys that move the insertion point in the Programmers pane.
Selecting text
You can select text with key combinations and the mouse.
To rename a subroutine or function, edit the script that defines it. If you change the name of a
Domino-defined subprogram such as Initialize or Click, a new user-defined subprogram with the revised
name is created and automatically added to the Info List. The script from the original event is moved to
the newly-created subprogram, and the original script becomes empty.
1:10
Note that even if the options are disabled you can still use the menu commands or accelerator keys to
display pop-up lists or boxes.
To redisplay a parameter box, if one is applicable in this situation, you can do either of the following:
v Choose Edit - Parameter Info from the menu
v Press CTRL+SHIFT+SPACE
Note: Any changes made to the Java files in the current agent exist only in the agent. If you want to
update the original files, you must export the agent to the directory containing the files you want to
update.
6. (Optional) Click New Class to add a new class. A horizontal bar separates each class. The name of a
class appears on the bar above the class to which it refers.
7. Click on Compile below the Script area. You can choose to compile the current class or the entire
agent.
8. (Optional) Click Export to export Java to a project directory.
If a Java agent is running on a server, the Java Debug Console output is redirected to a server log file.
Compiling Java
There are three ways to compile Java:
v A complete compilation occurs when you choose File - Save. All compile-time errors are reported at
this time.
v You can compile each class individually by clicking the class in the Script area, then clicking Compile
and selecting Compile Class Name.
v Compile all of the classes at once by clicking the Compile button and selecting Compile All.
Errors are reported in the Errors box. Click the Errors box to see which line in the Script area contains the
error.
Exporting Java
You can export the Java code you wrote in a Java agent or Java script library to the file system.
1. Make sure the code compiles and runs as expected.
2. With the Java agent or script library open in the programmers pane, click Export.
The Choose Base Directory dialog box displays.
48 Prgramming Guide, Volume 1: Overview and Formula Language
3. Select the directory you want to save the Java code to.
4. Click Ok.
The resulting file is called JavaAgent.java.
For details on exporting Java applets, see the Including Java applets in applications chapter in the
Application Development with Domino Designer book.
Importing Java
Select Imported Java from the Run menu.
1. Click Import Class Files.
2. Under the Available Java Files column, select the filing system and base directory for the files you
want to import. If you are importing from a named package, the base directory must be above the
directory containing the class files.
3. (Optional) Select the appropriate check box for Show file types. The default file type is All.
4. Select the files you want to import from the file list and click Add/Replace File(s). To import all of the
files in the base directory and all of its subdirectories, click Add/Replace All. To remove a file, or
group of files from the Current Agent Files column, select the file(s) and click Delete.
5. Put the files in the proper order in the Current Agent Files column by clicking Reorder Up or Reorder
Down to move files up or down, or by dragging files into place. You may move files one at a time, or
in groups.
6. Enter the base class in the Base class box or select it from the list.
7. (Optional) Click Refresh, or Refresh All to reload files in the Current Agent Files column.
8. Click OK to import files.
9. (Optional) Click Reimport Class Files to import additional files, or reimport an existing file.
Compiling JavaScript
JavaScript is compiled by choosing File - Save, or clicking the green check mark,
but it is not stored in its compiled form. All JavaScript is recompiled each time it is run.
Errors detected when the script is saved are displayed in the status bar at the bottom of the Script area.
Only one error is displayed at a time. Once an error is detected, you must correct the errors before you
can exit the design element. If you want to save a script with errors, make the incorrect line a remark by
preceding it with two forward slashes. For example:
// This is a remark.
or
/*
this is statement one.
this is statement two.
*/
You can also copy JavaScript to a file by using the File - Export menu command. Select an existing file or
type a new file name with the JS extension and click Export.
Compiling LotusScript
Compilation takes place in two phases:
1. A partial compilation occurs as you enter the script. Syntax and other per-line errors are reported at
this time.
2. A complete compilation occurs when you save the script. All remaining compile-time errors are
reported at this time.
If you attempt to save a script with compilation errors, you are given a choice of editing the script again
or exiting without saving your changes. If you exit, all changes are lost.
If you want to save a script with errors, make the incorrect line a remark by preceding it with an
apostrophe or a REM statement, or setting it off with a %REM ... %END REM directive.
If you change (Globals) on a form, all scripts associated with the (Globals) script, with the form, and with
all objects on the form are recompiled. Scripts in shared fields and subforms are not recompiled since
they arent on the form.
If you change the script for an object on a form, all events associated with the object, but nothing else, are
recompiled.
You can also copy LotusScript to a file by choosing File - Export. Select an existing file or type a new file
name with the LSS extension and click Export. From the LotusScript Export Options dialog box select
Current section only to export the current script, view, form, or agent object. Select Current object
Selecting a subprogram
As you execute a script the current subprogram appears in the debugger window.
The Calls tab contains a list of the subprograms currently in the execution stack in order of execution,
with the currently executing subprogram at the top of the list. Subprograms are listed as object: event, for
example, Calculate_totals: CLICK.
After you set a breakpoint, you can permanently clear it, temporarily disable it, or enable it again.
Breakpoints are displayed as red stop signs
when disabled.
For a statement continued over multiple lines, the last line is highlighted during stepping and stopping
on a breakpoint. To set, disable, enable, or clear a multi-line statement, you must select the last line.
A breakpoint remains in a script until you explicitly clear it. When an executing script first displays in the
debugger, any breakpoints that were not cleared from the last debugging session reappear.
The variables defined for the procedure appear in a three-column display, showing the name, value, and
data type of each variable. To view array or type members, click the arrow to the left of the variable
name.
The output panel displays script output, for example, the content of a Print statement. You can:
v View the output.
More than one user can attach to and debug the same agent. However, only one user has control to
debug it at any given time. A second user may get control by attaching to the same agent. This capability
is useful, for instance, if you want help from a coworker in debugging an agent. You can ask the
coworker to attach to and debug the server agent and that coworker can do so without having to be in
the same physical location as you. Note that if you attempt to continue debugging the server agent after
your coworker has attached to and begun to debug it, you will get the error, Another user has attached
to the agent and taken control. Please try to reconnect for further debugging.
To debug a scheduled LotusScript agent remotely defines how to use the remote debugger once the
server and agent are set up to allow for remote debugging.
Tip: You must have administrative access to the server to edit this field.
3. Enter a time limit for running the rdebug task on the server in the Turnoff Server Debug after setting.
Tip: If you set this value to -1, the task can run forever.
4. Enter a time interval in the Agent Wait at Start Time field if you want to force the agent to pause
before running, giving you time to attach the remote debugger to the target agent. (Recommended.)
5. Check the Ports - Internet Ports - Remote Debug Manager tab, to ensure that the TCP/IP port status
property is set to Enabled.
6. Make sure you are listed on the servers Security tab as having permission to run agents.
7. Save and Close the server document.
Tip: You can also add the following statement to the start of the agent code to broadcast to the
console that the agent is preparing to run.
Print "AgentName is about to start running****************"
4. On the Security tab of the Agent Properties box, select Allow remote debugging.
Tip: You know an agent is running if you added print and stop statements at the beginning of its
Initialize event. The print statement cause the agent to print to the console when it is starting and the
stop statement delays its execution.
The Domino Debugger 6 welcome page opens.
3. Select File - Select Debug Target from the menu.
The Select Debug Target dialog box displays.
4. Choose the server that is running the agent from the Server list box and click Open.
A list of the databases on the server displays.
5. Select the database that contains the agent and click Open.
If the agent you want to debug is currently running, it appears in the Debug Target box.
6. Select the agent you want to debug from the Debug Target list and click Open.
The Script Debugger window opens, displaying the (Options) event.
Note: To set a breakpoint, highlight the line you want to break before executing and choose File -
Set/Clear Breakpoint or F9.
3. As the code executes, the debugging results display in the Utility pane. The Utility pane contains the
following tabbed sections:
Tab Description
Breakpoints Lists the locations of breakpoints you have added to the code.
Calls Identifies what is currently being executed in the agent and displays all subprograms
currently on the execution stack. For example, folderDocs:INITIALIZE 5 indicates that the
fifth line of the Initialize event in the folderDocs agent is the next line to execute.
Output Displays the server console output. Any print statements in the code or error messages
appear here.
Variables Lists the variables created and their values as values are applied to them in the code.
You can use the edit box at the bottom of the pane to change the value of the selected
variable.
Java code from a script library runs in the context of the calling code.
Pick a port number that you think is free. This may require trial and error.
If changes are made to the foreground or background preference, Notes must be restarted. If changes are
made to the Web preview preference, the preview must be restarted.
If you are compiling the Java to be debugged outside Domino Designer, compile it with the -g option.
After modifying an agent or Web service, export the source code to a file that is accessible to your
debugger.
After you attach the debugger, you will see the execution threads for the JVM. An agents thread looks
something like this:
Thread(AgentThread: JavaAgent)(Running)
You can suspend the agents thread to gain control over it. At this point, the usual debugger features
become available (setting breakpoints, stepping, continuing, viewing variable values, and so on).
The Java agent must run long enough for you to attach the debugger to the JVM. You might delay
execution at the beginning of the procedure, for example, by inserting a loop with sleep statements.
If Notes and the debugger are on separate computers, and you get the error Failed to connect to remote
VM, the designated port is probably taken by another process. Try specifying another port number and
restarting Notes.
Security considerations
Java debugging over a network is insecure. You should restart Notes or the Web preview without Java
debugging enabled when youre not debugging.
The scope of a script library is the current database. All scripts in a database can avail themselves of the
LotusScript, JavaScript, or Java in a library in that database. However, the library is lost to scripts outside
the database. For example, if a button in a document uses a script library and you mail the document to
or paste it into another database that does not have the same script library, the script fails. If a script
attempts to use a library not in the current database, the error message, Error loading USE or USELSX
module displays.
You cannot change a declaration in a script library while a script or agent using that declaration is open.
You must first close the script or agent using the declaration, make the change in the library script, and
then reopen the script using the declaration. If you do make a change while a script is open, you must
comment out or delete the script that uses the declaration, close and reopen the script, and then reinsert
or remove the comments from the script.
See Recompiling all LotusScript for details on how you can find and update scripts that incorporate
libraries you have made changes to.
Being able to recompile all the LotusScript code in a database is especially useful if, for instance, you
want to make a change to a LotusScript script library that you have incorporated into several design
elements across a database. By recompiling all LotusScript, you can retrieve a list of all the design
elements that incorporate the now incorrect code and use your time to fix the code rather than to try to
find coding errors and inconsistencies.
A recompile takes two passes at a database. The first pass identifies all the elements that contain
LotusScript code and need to be recompiled. The second pass recompiles all the elements identified in the
first pass and saves them again. It then displays a list of those elements in which it found scripting
errors. You can open each element from the list to find and fix its errors.
Tip: The Recompile option of the Tools menu is not enabled if you do not have a specific database or
a design element from a specific database selected.
The Compile all LotusScript in dbname dialog box displays and begins recompiling the LotusScript
code in the database. (dbname is the name of the current database)
Tip: To stop recompilation, press CNTRL+BREAK, then Cancel. Canceling the operation may leave
some LotusScript objects in an inconsistent state.
2. If none of the LotusScript code in the database has any errors, the Design Elements list displays all
the elements that were compiled and All code successfully compiled displays below it. Click Ok to
close the dialog box.
3. If any errors are found, the Design Elements list displays the elements that contain errors and Not all
elements compiled successfully displays below it. Either:
v To close the dialog box without fixing the incorrect code, click Cancel.
v To edit an element, select it from the list and click Ok.
The selected element displays in the programmers pane.
4. Click each script object to display its associated code and find the error.
The text of the line of code that contains the error displays in red and the error is defined in the
Errors box. You cannot save and close the object until all errors present are corrected.
Tip: If you want to save a script with errors, make the incorrect line a remark by preceding it with an
apostrophe or a REM statement, or setting it off with a %REM ... %END REM directive.
5. Once you have fixed and closed the element, rerun the tool to display any elements that contain
remaining errors.
6. Repeat the process until no more errors are reported.
Note: You can also click the Reference tab to see a list of @functions, @commands, and fields.
5. Click the check mark that appears on the right just above the Script area to accept your new formula
or the edits to an existing formula. You can click the X to cancel your formula or edits.
6. If you receive syntax error messages, edit the formula until the errors are corrected.
The column formula has the appearance of a Programmers pane but lacks an Object box. Your formula
applies to the column that is currently selected.
and an X
appear next to the Formula window when you begin typing. Click the check mark to accept any
changes you have made. Click the X to undo any changes made prior to clicking the check mark.
3. If you receive syntax error messages, edit the formula until the errors are corrected.
For additional information, see URL commands for Web applications in Application Development with
Domino Designer.
Formula language
The formula language works, with restrictions, for Web applications. The formula language is particularly
useful for implementing Notes client menu commands as buttons, hotspots, and actions in the browser
environment where the Notes client menu is not available. This section describes:
v Where formulas work on the Web
v @Functions on the Web
v @Commands on the Web
67
Type of formula Application
Keyword field Works in a browser.
Named element Works in a browser.
Replication Applies to the back-end database.
Section access Works in a browser.
Section title Works in a browser.
Selection Works in a browser.
Toolbar button Applies only to the Notes client.
Window title Works in a browser.
The @BrowserInfo function returns information about a browser depending on the parameter value. The
following example gets the browser type and platform if the user is running from a browser:
@If(@ClientType = "Web";
"You are running from a " + @BrowserInfo("BrowserType") +
" browser on " + @BrowserInfo("Platform");
@ClientType = "Notes";
"You are running from a Notes client on " + @Platform;
"You are not running from a browser or a Notes client")
Opening a URL
The @URLOpen function opens the Web page specified by a URL. This example opens lotus.com:
@URLOpen("http://www.lotus.com")
In Web applications, you must specify the parameter. You cannot bring up the URL Open dialog box.
@WebDbName substitutes a forward slash for a back slash, and %20 (hexadecimal 20) for a space. It is
equivalent to:
Note: @WebDbName is new with Release 6. Earlier releases require the formula with @DbName,
@Subset, and @ReplaceSubstring.
The @SetHTTPHeader function sets the value of an HTTP request-header field. This example sets the
value of the Set-Cookie field:
@SetHTTPHeader("Set-Cookie"; "COOKIE1=4646")
To get only the value of a parameter, specify the parameter name, for example:
@UrlQueryString("Category")
To return an encoded URL that can be used as an address, do not encode an entire URL, as that will
remove necessary punctuation. Instead, encode only the final information, for example:
"http://www.acme.com/" + @URLEncode ("Domino";"4Q profit&loss")
Field validation
@Success and @Failure work in field input validation formulas on the Web. The @Failure path causes the
message specified as the parameter to appear on a new page. In the following validation formula, if the
user fails to enter a value for RequiredField, the word Gong in bold appears on a new page:
@If(RequiredField = ""; @Failure("<B>Gong<\B>"); @Success)
You can make the failure page more meaningful by using more extensive HTML in the error message:
msg1 := "This is a required field.<br><br>";
msg2 := "<a href=/" + @WebDbName + "/Main+Document?OpenForm>";
msg3 := "Click here</a> to try again.";
msg := msg1 + msg2 + msg3;
@If(RequiredField = ""; @Failure(msg); @Success)
Note: When called from an action on a page or document in a Web application, @DbCommand acts on
an embedded view in the same page or document.
Restricted @functions
The following @functions do not work or are restricted on the Web.
CalendarFormat
The CalendarFormat @command changes the number of days that a calendar view displays. The Web
options are:
@Command([CalendarFormat] ; "1")
@Command([CalendarFormat] ; "2")
@Command([CalendarFormat] ; "7")
@Command([CalendarFormat] ; "14")
@Command([CalendarFormat] ; "30")
@Command([CalendarFormat] ; "365")
CalendarGoto
The CalendarGoto @command goes to a specified date in a calendar view. The following example goes to
todays date:
@Command([CalendarGoTo]; @Today)
Compose
The Compose @command creates a new document.
To create a main document in the current database, specify only the form parameter and implement
Compose in a view, page, or navigator. The following example, implemented as a view action, creates a
main document based on the Main Topic form.
@Command([Compose]; "Main Topic")
To create a main document in another database, specify the database and form parameters. You must
specify server as an empty string because the browser cannot access another server. The following
example creates a new document in document examples.nsf based on the Main Topic form in that
database.
@Command([Compose]; "" : "document examples.nsf"; "Main Topic")
or
@Command([Clear])
For Web applications, you can implement these @commands only in a form. After the deletion, a
document with the text Deleted replaces the current document.
In the Notes client, these @commands mark documents for deletion or delete text, depending on the
design element they are used in.
EditDocument
The EditDocument @command toggles a document between Read and Edit modes:
@Command([EditDocument])
For Web applications, you cannot use the mode and previewpane parameters.
EmptyTrash
The EmptyTrash @command deletes the documents marked for deletion and refreshes the current view.
@Command([EmptyTrash])
This @command works for a view on the Web if Use applet in the browser or Allow selection of
documents is in effect.
See FileSave for using FileCloseWindow or CloseWindow with FileSave to submit a document.
FileCloseWindow and CloseWindow do not work on the Web unless Use JavaScript when generating
pages is set in the database properties. This is the default.
FileSave
The FileSave @command saves the current document, which must be open for editing.
To submit a document that is open for editing, issue FileSave followed by OpenView, FileCloseWindow,
or CloseWindow. This can be implemented as a form action or button.
Using FileSave followed by OpenView saves the document then opens a specified view in the browser,
for example:
@Command([FileSave]);
@Command([OpenView]; "All Documents")
Using FileSave followed by FileCloseWindow or CloseWindow saves the document then uses the
$$Return field or lack thereof to determine what to open next in the browser.
@Command([FileSave]);
@Command([FileCloseWindow])
or
@Command([FileSave]);
@Command([CloseWindow])
If the document contains no $$Return field, the browser displays a page with the message, Form
processed.
If the document contains a $$Return field, the browser displays its HTML or follows a link. Typically
$$Return is a computed for display text field. The following example presents some text followed by a
view link:
"<h3>Document submitted<h3><hr><font size=2><a href=/" +
@WebDbName +
"/All%20Documents?OpenView>All Documents view</a>"
To have the browser follow a link, specify the formula for the $$Return field as a Domino URL command
in brackets. The following example opens a view:
"[/" + @WebDbName + "/All%20Documents?OpenView]"
See Customizing Form processed confirmation for the Web in Application Development with Domino
Designer for more information.
FileSave does not work on the Web unless Use JavaScript when generating pages is set in the database
properties. This is the default.
MoveToTrash
The MoveToTrash @command marks selected documents in a view or folder for deletion.
@Command([MoveToTrash])
This @command works for a view on the Web if Use applet in the browser or Allow selection of
documents is in effect.
or
@Command([NavNext])
For Web applications, you can only use these @commands on forms; you cannot use them in views or
folders.
or
@Command([NavNextMain])
For Web applications, you can only use these @commands on forms; you cannot use them in views or
folders.
or
@Command([NavPrev])
For Web applications, you can only use these @commands on forms; you cannot use them in views or
folders.
For Web applications, you can only use these @commands on forms; you cannot use them in views or
folders.
OpenDocument
The OpenDocument command, used in conjunction with OpenView, opens an existing document in the
current database. The view must be sorted and the OpenView command must specify key exactly except
for case. For example, the following code opens the first document in Main View whose first sorted
column contains the value one:
@Command([OpenView]; "Main View"; "one");
@Command([OpenDocument])
For Web applications, you can open the first document in the view with the argument $first:
@Command([OpenView]; "Main View"; "$first");
@Command([OpenDocument])
To open the document in Edit mode, specify as 1 the writeOrReadOnly parameter to OpenDocument.
For example:
@Command([OpenView]; "Main View"; "one");
@Command([OpenDocument]; "1")
For Web applications, you cannot use the UNID and width:height parameters to OpenDocument.
The OpenDocument command, used in conjunction with FileOpenDatabase, opens an existing document
in another database. This example opens the first document in the All Documents view in document
examples.nsf:
@Command([FileOpenDatabase];
"" : "document examples.nsf"; "All Documents"; "$first");
@Command([OpenDocument])
OpenFrameset
The OpenFrameset @command opens a frameset.
@Command([OpenFrameset]; "WebToDoFS")
OpenNavigator
The OpenNavigator @command opens a navigator.
@Command([OpenNavigator]; "Main Navigator")
OpenPage
The OpenPage @command opens a page.
@Command([OpenPage]; "Page One")
OpenView
The OpenView @command opens a view in the current database. For example, the following code opens
Main View:
@Command([OpenView]; "Main View")
If key is specified, the view must be sorted and the OpenView command must specify key exactly except
for case. On the Web, the view opens with the row containing key at the top. The following code opens
Main View at the first row that contains the value one:
@Command([OpenView]; "Main View"; "one");
@Command([OpenDocument])
In the Notes client, you can specify a partial key, for example, o or on instead of one. In a Web
application, the key must be exact.
In a Web application, the argument $first for key means the first row.
RefreshFrame
On the Web, the RefreshFrame @command refreshes the current frame ignoring any parameter.
@Command([RefreshFrame])
RemoveFromFolder
The RemoveFromFolder @command removes selected documents from a folder.
@Command([RemoveFromFolder])
or
@Command([RunAgent]; "Status = open")
Agents run on the Domino server containing the database not on the browser computer. See Web
Agents.
or
@Command([SwitchView]; "Main View")
ViewCollapse
The ViewCollapse @command collapses everything in the current category or under the current main
document in a view.
@Command([ViewCollapseAll])
This @command works for a view on the Web only if Using Java Applet is in effect.
ViewCollapseAll
The ViewCollapseAll @command collapses a view so that only the topmost level of category names
appears.
@Command([ViewCollapseAll])
ViewExpand
The ViewExpand @command expands everything in the current category or under the current main
document in a view.
@Command([ViewCollapseAll])
This @command works for a view on the Web only if Using Java Applet is in effect.
ViewExpandAll
The ViewExpandAll @command expands a view so that all levels appear.
@Command([ViewExpandAll])
This @command works on the Web only if Use applet in the browser is in effect for the implementing
view or folder.
ViewShowSearchBar
In a Web application, the ViewShowSearchBar @command opens the search view.
@Command([ViewSearchBar])
In the Notes client, this @command toggles the search bar in a view.
Web agents
Agents cannot run in a browser. They can be activated from a browser but run on the Domino server
containing the agent.
The name of a hidden agent (for example, if the trigger is Agent list selection) must include the
parentheses when RunAgent or ToolsRunMacro launches the agent. The parentheses are optional when
the OpenAgent URL command launches the agent. The OpenAgent URL requires conversion of special
characters for Web use; for example, a space must be specified as + (plus sign) or %20.
To prevent the document from being saved, the document must contain a text field named SaveOptions
with 0 as its value.
Note: The SaveOptions field must be an existing field, the value of which the Web agent changes to 0.
If the Web agent creates this field, the document will be saved regardless of the value.
An agent is the only context in which a Web application can use LotusScript. Anything that runs in the
browser, such as an action, hotspot action, hotspot button, or event, cannot contain LotusScript.
LotusScript agents activated from the Web cannot use any of the classes NotesTimer, NotesUIDatabase,
NotesUIDocument, NotesUIView, or NotesUIWorkspace.
You can write HTML to the browser by putting it in print statements. Domino accumulates print
statements and creates a page with their contents after the agent runs.
To display a new page after an agent runs, put one print statement at the end of the code containing the
pages URL in brackets. You can start the URL with a slash and the name of the database to designate an
element in the current database.
In Java, you must get a PrintWriter object with AgentBase.getAgentOutput and use this object to write to
the browser.
The OpenAgent URL command passes arguments at the end of the URL string delineated by
ampersands. For example:
http://host/database/view/OpenView&Start=1&Count=20
In LotusScript and Java agents, you can get the arguments by parsing the Query_String item in the
document returned by DocumentContext or getDocumentContext. Query_String contains the entire URL
command that started the agent.
try {
Session session = getSession();
AgentContext agentContext = session.getAgentContext();
} catch(Exception e) {
e.printStackTrace();
}
}
}
6. This agent parses Query_String to extract one argument, which must be Open or Closed. It must
be run with an OpenAgent URL command, for example,
http://localhost/Web+test.nsf/Change+Status?OpenAgent&Closed
Here is the code:
Sub Initialize
Dim s As New NotesSession
Dim db As NotesDatabase
Dim dc As NotesDocumentCollection
Dim doc As NotesDocument
Dim arg As String, p1 As Long
arg = s.DocumentContext.Query_String(0)
p1 = Instr(arg, "&")
If p1 = 0 Then
Print "Need argument Open or Closed"
Exit Sub
Else
arg = Lcase(Mid$(arg, p1 + 1))
If arg <> "open" And arg <> "closed" Then
Print "Argument must be Open or Closed"
Exit Sub
End If
End If
arg = Ucase(Left$(arg, 1)) + Right$(arg, Len(arg) - 1)
Set db = s.CurrentDatabase
Set dc = db.UnprocessedDocuments
Set doc = dc.GetFirstDocument
Do While Not(doc Is Nothing)
doc.Status = arg
Call doc.Save(False, True)
Set doc = dc.GetNextDocument(doc)
Loop
Print "<B>Status changed to "+ arg + " in all documents</B>"
End Sub
JavaScript
JavaScript executes in browsers and the Notes client providing a simple, effective way to program the
user interface. You can place JavaScript code in JavaScript events and for Web-only applications in
HTML. Domino Designer objects map to the standard JavaScript object model. Through JavaScript you
can access the Java/CORBA classes.
JSHeader event
JSHeader is a special event handler that loads code such as functions and global variable declarations
that all the events in the object can access. This code goes under the <HEAD> tag in Domino-generated
HTML.
onSubmit event
The onSubmit event occurs in a browser and the Notes client when the FileSave @command executes. In
a browser, you can return false from the onSubmit event to abort the save operation.
JavaScript in HTML
You can use JavaScript anywhere HTML can be placed by using the standard SCRIPT LANGUAGE tag as
shown below.
<SCRIPT LANGUAGE="JavaScript">
code goes here</SCRIPT>
Mark the code as HTML by selecting it then choosing Text - Pass-thru HTML.
Check Render pass through HTML in Notes in the Form or Page Properties box to have the Notes
client process the HTML. If you do not check Render pass through HTML in Notes, the HTML appears
as plain text. You can hide it using the following formula for Hide paragraph if formula is true:
@ClientType = "Notes"
If you refer to a field, the JavaScript code must follow the field on the form.
You can embed computed fields and computed text in HTML text on a form, subform, or page.
You can place JavaScript in a URL using the javascript: protocol, for example:
<A HREF="javascript:code goes here">prompt</A>
To run an agent from JavaScript, set the href property of the location object to the URL for opening the
agent. The URL can be relative to the current host. For example:
location.href = "/dbname.nsf/agentname?OpenAgent&arg1=val"
Browser implementation of the object model depends upon the browser. The Notes client implements the
object model with some exceptions. For information on the Notes implementation, see the Notes Release 5
Client Document Object Model in http://www.lotus.com/ldd/doc.
The JavaScript objects map to the Domino design elements as discussed in the following sections.
Navigator
The navigator object applies to the currently opened form, page, view, or frameset. The appName,
appCodeName, appVersion, platform, and userAgent properties apply to the invoking browser or client
and return the same information no matter what the base Domino Designer object is.
Window
The window object applies to the currently opened form, page, view, or, for a frameset, the frame that is
in focus. Suppose you design two pages named Page One and Page Two, and a frameset with two
frames named High and Low, where High opens Page One and Low opens Page Two. If you
open Page One on its own, window.status means the status property of Page One. If you open the
frameset, window.status means Page One when the focus is on High and Page Two when the focus
is on Low.
Frame
Domino frames can be accessed by name and through the frames array. The name is as specified in the
Frame Properties box. Use window.top to access the window representing the frameset. For example, if a
The name property initially contains the Domino frame name and is empty if the window does not
represent a Domino frame.
Nested frames represent nested Domino framesets. For example, if the Low frame contains another
frameset with two frames named Left and Right, you can refer to Left as window.top.Low.Left,
window.top.frames[1].frames[0], or some combination of names and frame elements.
Use the parent property to access the parent window of a frame. If the focus is in the Right frame in
the above example, window.parent refers to window.top.Low and window.parent.Left refers to the
adjacent window.top.Low.Left.
Document
The document object represents the contents of the currently open Domino form, page, or view. The
document object contains the following:
v The applets array includes Domino action bar, view, and rich text applets as well as applets you
import. Applets are represented by the <APPLET> tag in HTML. You can refer to an applet by name,
for example, document.AppletName, if you specify a name under the HTML tab of Applets properties.
For more information, see the help topic Adding an applet, or Designing Pages in Application
Development with Domino Designer.
v The links array includes Domino actions, link hotspots, and action hotspots, which are represented in
HTML by the <A> tag. You can refer to action hotspots by name, for example,
document.HotspotName, if you specify a name under the HTML tab of the HotSpot Properties box.
Domino link hotspots do not contain event handlers. However, you can specify a handler in Other
under the <HTML> tag of the HotSpot Properties box.
v The images array includes Domino attachments, image resources, and pictures, which are represented
in HTML by the <IMG> tag. You can refer to pictures by name, for example, document.PictureName, if
you specify a name under the HTML tab of the Pictures Properties box.
You can refer to a Domino image resource with a URL that specifies the database name or replica ID
followed by the name of the image resource, for example, /Web+Test.nsf/newdam.gif.
v The forms array typically has one element, document.forms[0] named _DominoForm, which is
represented in HTML by the <FORM> tag. It has an array of named elements that contains any objects
of type Button, Text, Textarea, Password, Select, Radio, Checkbox, Hidden, and FileUpload.
v The Button object represents Domino buttons, which are represented in HTML by the <INPUT
TYPE=button> tag. You can refer to buttons by name, for example, document.forms[0].ButtonName, if
you specify a name under the HTML tab of the Button Properties box.
v The Text object represents Domino fields of type Text, Date/Time, Number, Names, Authors, and
Readers, which are represented in HTML by the <INPUT> tag. You can refer to Text objects by their
Domino field names, for example, document.forms[0].FieldName.
v The TextArea object represents Domino fields of type RichText. It is represented in HTML by the
<TEXTAREA> tag. You can refer to TextArea objects by their Domino field names, for example,
document.forms[0].FieldName.
v The Password object represents Domino fields of type Password, which are represented in HTML by
the <INPUT TYPE=password> tag. You can refer to Password objects by their Domino field names, for
example, document.forms[0].FieldName.
v The Select object represents Domino fields of type Dialog list, Listbox, and Combobox, which are
represented in HTML by the <SELECT> tag. You can refer to Select objects by their Domino field
names, for example, document.forms[0].FieldName.
The names of Domino fields are case sensitive. In Edit mode, Domino fields are accessible to JavaScript in
a browser and the Notes client with restrictions as noted for hidden fields. In Read mode, Domino fields
are not accessible to JavaScript in a browser unless Generate HTML for all fields is selected in the Form
Properties box. In Read mode, Domino fields are never accessible to JavaScript in the Notes client.
You can then use the returned Session object to get at the other Domino objects. If you instantiate other
Domino objects in the Java applet, you can use them directly in the JavaScript code.
In the Notes client, you can call AppletBase.getContext(Session) to get a NotesAppletContext object. This
object contains the following methods: getServer( ) returns the name of the server containing the applet
or a blank string for a workstation; getDatabase( ) returns the file path and name of the database
containing the applet; getDocument( ) returns the universal ID of the document containing the applet or
null if the document has not been saved.
Web services
Note: Web services are new with Release 7.
Domino supports Web services as defined in the W3C documents Simple Object Access Protocol (SOAP) 1.1
(http://www.w3.org/TR/2000/NOTE-SOAP-20000508) and Web Services Description Language (WSDL) 1.1
(http://www.w3.org/TR/2001/NOTE-wsdl-20010315). See also Web Services Architecture
(http://www.w3.org/TR/ws-arch) and Web Services Activity (http://www.w3.org/2002/ws/).
Development in Domino Designer is through a Web service design element coded in Java or
LotusScript. The code defines and implements the service. The Web service also maintains the definition
as a WSDL (Web Services Description Language) document.
v The compiled Web service, like an agent, is a stand-alone program in a Domino database. To be used,
the Web service must be on -- or be replicated to -- a server that is enabled for Web access. It can then
be accessed with the following Domino URLs:
OpenWebService -- using HTTP POST protocols, invokes the Web service. If HTTP GET protocols
are used, OpenWebService returns some information about the service.
WSDL -- queries the Web service for its WSDL document.
v A Web service can be tested through an HTTP session in Notes or Designer preview.
v A Web service has the same security capabilities as an agent.
v You can import an existing WSDL document to generate a skeleton Web service. The skeleton code
corresponds to the Web service definition. You then add implementation code.
v Alternatively you can start a Web service from scratch, writing your own Java or LotusScript code to
create the Web service definition.
v In Domino Designer, you can show or export the WSDL document that defines the Web service. For
Java, you can export the source, create a new class, edit the project files, and compile the project files
(as for a Java agent).
A WSDL document defines a Web service and incorporates the following elements:
v Service -- The Web service as a whole. In a WSDL document, the service is described by a
<definitions> element at the root. Children are <types>, <message>, <portType>, <binding>, and
<service>. The <service> element has a name attribute that names the service.
v Types -- The data types used by the service. In a WSDL document, the data types are described in a
<types> element containing an <xsd:schema> element. See http://www.w3.org/TR/xmlschema-2 for
descriptions of the data types.
v Message -- An abstract definition of data being communicated to or from the service. There may be
any number of messages. In a WSDL document, each message is described by a <message> element.
Each <message> element contains one or more <part> elements to define the data by name and type.
v Port type -- An abstract set of operations supported by the service. In a WSDL document, a port type is
described by a <portType> element. Each <portType> element contains one or more <operation>
elements.
v Operation -- An abstract description of an action supported by the service. In a WSDL document, an
operation is described by an <operation> element. Each <operation> element contains <input> and
<output> elements that specify associated messages.
v Binding -- A concrete protocol and data format specification for a port type. In a WSDL document, a
binding is described by a <binding> element. A <binding> element has a type attribute that specifies
the name of the port type. For SOAP encoding, a <binding> element contains a <soap:binding>
element with style (rpc or document) and transport (http://schemas.xmlsoap.org/soap/http)
attributes. A <binding> element contains <operation> elements that describe the data format for each
operation.
v Port -- A single endpoint defined as a combination of a binding and a network address. In a WSDL
document, a port is defined by a <port> element under the <service> element. The <port> element has
a binding attribute to name the binding and an address location attribute to name the network
endpoint to be associated with the binding.
Basics tab
The Basics tab of the properties box contains:
v Name, Alias, Comment -- Identify the Web service just as you would any other design element such as
an agent.
v Options -- You can check Warn if the WSDL interface is modified.
v PortType class -- Specify the class that contains the operations (the implementation code) for the port
type. (You have to create the class first.)
Advanced tab
The top of the Advanced tab of the properties box specifies the programming model and SOAP message
format. Select one of the following combinations. The descriptions below explain how the options affect
the WSDL document:
v RPC programming model, RPC/encoded
For <wsdl:message>, <wsdl:part>: type= specifies an XSD type or a type defined in <wsdl:types>
For <wsdlsoap:binding>: style=rpc
For <wsdl:operation>, <wsdl:input> and <wsdl:output>, <wsdlsoap:body>:
encodingStyle=http://schemas.xmlsoap.org/soap/encoding/
For <wsdl:operation>, <wsdl:input> and <wsdl:output>, <wsdlsoap:body>: use=encoded
v RPC programming model, RPC/literal
For <wsdl:message>, <wsdl:part>: type= specifies an XSD type
For <wsdlsoap:binding>: style=rpc
For <wsdl:operation>, <wsdl:input> and <wsdl:output>, <wsdlsoap:body>: use=literal
v RPC programming model, Doc/literal
<wsdl:types> defines an element for each input and output
For <wsdl:message>, <wsdl:part>: element= specifies an element defined in <wsdl:types>
For <wsdlsoap:binding>: style=document
For <wsdl:operation>, <wsdl:input> and <wsdl:output>, <wsdlsoap:body>: use=literal
v RPC programming model, Wrapped
<wsdl:types> defines a single complex element for each operations inputs and a single complex
element for each operations outputs, with no attributes; each complex element is named for its
corresponding operation
For <wsdl:message>, <wsdl:part>: element= specifies an element just defined in <wsdl:types> (each
<wsdl:message> has a single <wsdl:part> where name=parameters)
For <wsdl:portType>, <wsdl:operation>: parameterOrder=
For <wsdlsoap:binding>: style=document
Editor pane
The editor pane of the Web service consists of either Java or LotusScript code.
v Data types -- The Java or LotusScript code defines a class for each data aggregate. In the WSDL
document, these classes appear as <complexType> elements, and also <simpleType> elements with
enumeration restrictions (facets). Primitive data types and arrays of primitive data types are mapped
directly as specified below under Java and LotusScript mappings.
v Implementation (or PortType) class -- The Java or LotusScript code defines a class that contains a
public method, function, or sub for each operation in the Web service. In the WSDL document, these
operations appear as <wsdl:operation> elements under <wsdl:portType>. The name of the class must
match PortType class in the Basics tab of the properties box (the term PortType comes from the
W3C specification for WSDL documents).
In the simple case where an operation has one output part that is not also an input part: the
parameters in the Java or LotusScript code map to the <wsdl:input> message for the operation; the
return value maps to the <wsdl:output> message. In other cases, for Java: output parts and inout parts
map to parameters that are classes that implement the interface javax.xml.rpc.holders.Holder
(StringHolder, FloatHolder, and so on); for LotusScript: output and inout parts similarly map to
HOLDER classes defined in lsxsd.lss (STRING_HOLDER, SINGLE_HOLDER, and so on).
Operations may also return errors to the caller, either through a fault sub-class that corresponds to
some <wsdl:fault> message specified for the operation in the WSDL document, or through direct use of
the WS_FAULT base class (LotusScript), or the lotus.domino.types.Fault or java.lang.Exception classes
(Java).
To invoke a Domino Web service, a consumer uses the Domino URL command for opening the design
element in a SOAP-encoded Web services HTTP POST request. Domino executes the appropriate
implementation code based on the request and sends a SOAP-encoded response to the consumer.
The syntax for the Domino URL command for a Web service is as follows:
http://servername/databasename.nsf/webservicename?OpenWebService
If you send the URL command for opening a Web service to a Domino server in an HTTP GET request
(for example, by typing the command in a browser), Domino responds with the Web services port name
and the names of the operations for the port.
The following Domino URL command retrieves the WSDL document for the Web service in response to
an HTTP GET:
http://servername/databasename.nsf/webservicename?WSDL
The SOAP address for a Web service is the Domino server responding to the WSDL URL command. The
SOAP address in a WSDL document generated by Domino Designer is not valid because the Web service
is not properly exposed on a server at that time.
The lotus.domino package contains the class WebServiceBase which contains the static method
getCurrentSession. Use this method to get a Session object representing the Domino session, typically in
the no-parameter constructor for the implementation class. The Domino Web services runtime engine
invokes the implementation class no-parameter (default) constructor and ignores all other constructors.
The default constructor may not be explicit, but when it is, it must be declared public. Other constructors
may also be present, for use by the implementation.
Session.getAgentContext() gets the Web service context. The following AgentContext properties apply to
Web services: getCurrentAgent() gets the current Web service; getCurrentDatabase() gets the current
database. For getCurrentAgent(), the following Agent properties apply to the current Web service:
getName(), getOwner(), getCommonOwner(), getOnBehalfOf(), getComment(), getHttpURL(),
getNotesURL(), getParent(), and getLockHolders().
The (Declarations) typically include Dim statements for NotesSession and NotesDatabase (for the current
database) objects.
Use Sub NEW in the implementation class for code that is always executed prior to the invoked
operation, such as setting the NotesSession object. Creating a new NotesSession object gets a Domino
session. Sub NEW may not have arguments in its signature. The same restriction applies to Sub NEW for
all classes received or returned by any Web Service method (including classes contained in other classes).
The following NotesSession properties apply to Web services: CurrentAgent gets the current Web service;
CurrentDatabase gets the current database. For CurrentAgent, the following NotesAgent properties apply
to the current Web service: Name, Owner, CommonOwner, OnBehalfOf, Comment, HttpURL, NotesURL,
Parent, and LockHolders.
The following LotusScript XSD classes are proxy classes: XSD_BASE64BINARY, XSD_DATE,
XSD_DATETIME, XSD_HEXBINARY, and XSD_TIME. Like the other XSD classes, they have a public
variable named Value that you can get and set. However, the Value variable is not of type String.
The information for the classes XSD_BASE64BINARY and XSD_HEXBINARY is passed in NotesStream
format. These classes have the following function and sub:
NotesStream = GetValueAsNotesStream()
Call SetValueFromNotesStream(NotesStream)
The information for the classes XSD_DATE, XSD_DATETIME, and XSD_TIME is passed in
NotesDateTime format. These classes have the following function and sub:
NotesDateTime = GetValueAsNotesDateTime()
Call SetValueFromNotesDateTime(NotesDateTime)
The data types map both ways (WSDL document to code and vice-versa) except as noted.
Arrays
Arrays map to XML Schema <complexType> entities elements in WSDL, with the following attributes
and subelements:
v name = ArrayOf_xsd_ plus the name of the data type; for example, ArrayOf_xsd_int
v restriction base = soapenc:Array
v attribute ref = soapenc:arrayType
v wsdl:arrayType = xsd: plus the data type plus []; for example, xsd:int[]
For example, an array of type int (Java) or Long (LotusScript) generates the following WSDL:
- <wsdl:types>
- <schema targetNamespace="urn:DefaultNamespace"
xmlns="http://www.w3.org/2001/XMLSchema">
<import namespace="http://schemas.xmlsoap.org/soap/encoding/" />
- <complexType name="ArrayOf_xsd_int">
- <complexContent>
- <restriction base="soapenc:Array">
<attribute ref="soapenc:arrayType" wsdl:arrayType="xsd:int[]" />
</restriction>
</complexContent>
</complexType>
</schema>
</wsdl:types>
Arrays may also map to individual <element> entities in WSDL, where a maxOccurs attribute is present
with a value greater than 1. This second form of array representation may appear in any
externally-defined WSDL document, but will only appear in Designer-generated WSDL for a Java Web
service, and only then for Java value type array members with indexed accessors.
Classes
Classes (sometimes called value types) that pass to or from a Web service operation usually map to XML
Schema <complexType> elements in WSDL, with subelements representing each exposed data member.
For example:
<xsd:complexType name="telephone">
<xsd:sequence>
<xsd:element name="areaCode" type="xsd:int"/>
<xsd:element name="exchange" type="xsd:int"/>
<xsd:element name="number" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
For LotusScript, exposed class data members are those members declared public.
For Java, exposed class data members are either members that are public, or members that have public
get and set methods characteristic of a Java Bean. Recognizable Java value type classes must have a
public default constructor (no arguments).
Enumerations
Enumerations map to XML Schema <simpleType> elements in WSDL, with the following characteristics:
v restriction subelement with base attribute for the underlying type
For example, an enumeration of vegetables containing members of type String generates the following
WSDL:
<xsd:simpleType name="vegetableType">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Carrot"/>
<xsd:enumeration value="Lettuce"/>
<xsd:enumeration value="Ketchup"/>
</xsd:restriction>
</xsd:simpleType>
Both LotusScript and Java implementations of an enumeration reflect a specific pattern comprised of:
v a constant for each enumeration member value
v a class for representing any enumeration member
v a collection of the enumeration member class instances, representing the enumeration itself
v initializer code that populates the enumeration just prior to Web service method invocation
All identifying characteristics (bolded in the examples) must be present in the implementation for any
WSDL generation to detect and correctly represent an enumeration.
Note: the Java enumeration pattern prohibits the presence of a Java Bean set: method, i.e. a setValue
method with one parameter, where the parameter type matches the getValue method return type).
Faults
Faults communicate error conditions back to the caller, and may be emitted by any Web service method.
They may be explicit to the WSDL contract (specified in the WSDL document for one or more service
operations), or just implicit to the WSDL contract (implemented-only, as part of some Service methods
signature).
Explicit faults appear in WSDL as optional <wsdl:fault> elements specified for an operation, appearing
alongside <wsdl:input> and <wsdl:output> elements. For example:
<wsdl:operation name="getStockQuote">
<wsdl:input message="getStockQuoteRequest"/>
<wsdl:output message="getStockQuoteResponse"/>
<wsdl:fault name="InvalidSymbolFault" message="InvalidSymbolFaultMessage"/>
</wsdl:operation>
A <wsdl:fault> element is typed by its message attribute, just like an operations <wsdl:input> or
<wsdl:output> element.
Accordingly, a WSDL fault, through its associated message part type(s), maps to some class in the
LotusScript or Java implementation, which is sub-classed from either WS_FAULT (LotusScript) or
lotus.domino.types.Fault (Java).
This implementation fault subclass maps to the data members defined for the WSDL faults associated
message, in exactly the same manner as implementation value types (see Classes, above) map to their
associated WSDL constructs, usually WSDL <complexType>s.
For example, given the following WSDL complexType (specified here as the type for the example
InvalidSymbolFaultMessage referenced above):
<wsdl:types>
<xsd:schema ...>
<xsd:complexType name="InvalidSymbolFault">
<xsd:sequence>
<xsd:element name="TickerSymbol" type="xsd:string"/>
</xsd:schema>
</wsdl:types>
...
<wsdl:message name="InvalidSymbolFaultMessage" type="InvalidSymbolFault"/>
Sub NEW
End Sub
End Class
public InvalidSymbolFaultMessage() {
}
public InvalidSymbolFaultMessage(java.lang.String tickerSymbol, int applicationCode) {
this.tickerSymbol = tickerSymbol;
this.applicationCode = applicationCode;
}
public java.lang.String getTickerSymbol() {
return this.tickerSymbol;
}
public int getApplicationCode() {
return this.applicationCode;
}
// helper methods...
}
When a Web service operation has no need to send additional, service-specific, data back to the caller,
then explicit WSDL faults are not needed - an implicit fault will suffice, instead.
Implicit faults are always possible, are issued by the Web service framework for a variety of invocation
errors, but may be emitted, too, by any service method exposed in the implementation PortType class.
Note, too, that adding or removing implicit faults from an implementation method signature is not
treated as a change to the Web service contract, and so does not by itself cause WSDL regeneration when
the Web service is saved.
Service method fault handling is the same for both explicit and implicit faults. All identifying
characteristics are bolded in the examples.
Lists
The XML Schema list type is a form of <simpleType> whose values are represented as a single,
white-space delimited list. For example, the following sequence of vegetables (each token separated by a
space character):
Carrot Lettuce Ketchup
List values lend themselves to implementation as arrays, and therefore map to array-like implementations
in both LotusScript and Java. The identifying characteristics for WSDL generation are bolded in the
example.
Namespaces
XML Schema uses namespace qualifiers to differentiate among like-named but differently-defined
constructs, especially data types, for example:
<types>
<xsd:schema targetNamespace="urn:MyAddressBook" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:complexType name="telephone">
<xsd:sequence>
<xsd:element name="areaCode" type="xsd:int"/>
<xsd:element name="exchange" type="xsd:int"/>
<xsd:element name="number" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
Here, the telephone data type is specified to be part of the MyAddressBook namespace.
Domino Java Web service implementations represent mapped namespaces as Java packages, and so the
above telephone data type would map to the following Java package and class:
package MyAddressBook;public class Telephone {
...
}
LotusScript Web service implementations have no package construct to use in this manner, and the legal
length for a LotusScript identifier is limited, compared to Java. So WSDL XML Schema namespaces are
mapped either as namespace constants together with short suffixes appended to LotusScript class names,
or as a single, DefaultNamespace constant, applied as the default namespace.
For example, the above telephone data type would import from WSDL to LotusScript as the following:
Const n1 = "MyAddressBook" string constant value can be many characters long
Class Telephone_n1...
End Class
Unsupported constructs
For this release, the following WSDL or XML Schema constructs have limited or no supported mappings
to LotusScript or Java, and are rejected (or ignored, if indicated) by the Designer Import WSDL feature:
v any element
v anyAttribute element
v choice element, if nested, optional, or maxOccurs > 1 (arrays)
v redefine element
v sequence element, if maxOccurs > 1 (arrays)
v union simple type
v vector and map (APACHESOAP namespace) - no LotusScript mappings
v MIME attachments
102 Prgramming Guide, Volume 1: Overview and Formula Language
v simple type facets - ignored (except for enumeration)
v attribute, element default values - ignored
v mixed content (character data alongside complex type subelements) -- ignored
Similarly, the following LotusScript and Java constructs have no supported mappings to WSDL XML
Schema, and are rejected by the Designer Export WSDL, Show WSDL, or Save features, when
exposed as some Web service operation argument or return type:
v LotusScript list and currency data types
v LotusScript class Sub NEW and DELETE (constructor/destructor) arguments
v LotusScript LSX objects
v backend classes (except for NotesDomDocumentNode for use with message programming model)
v most Java non-Bean classes
LotusScript:
%INCLUDE "lsxsd.lss"
Class WebServiceOne
Sub NEW
End Sub
End Class
Java:
import lotus.domino.*;
import lotus.domino.types.*;
WSDL
<?xml version="1.0" encoding="UTF-8" ?>
<wsdl:definitions targetNamespace="urn:DefaultNamespace"
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:apachesoap="http://xml.apache.org/xml-soap"
xmlns:impl="urn:DefaultNamespace" xmlns:intf="urn:DefaultNamespace"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:message name="OPERATION2Request">
<wsdl:part name="INPUT1" type="xsd:string" />
<wsdl:part name="INPUT2" type="xsd:string" />
</wsdl:message>
<wsdl:message name="OPERATION1Response">
<wsdl:part name="OPERATION1Return" type="xsd:string" />
</wsdl:message>
<wsdl:message name="OPERATION1Request">
<wsdl:part name="INPUT1" type="xsd:string" />
<wsdl:part name="INPUT2" type="xsd:string" />
</wsdl:message>
<wsdl:message name="OPERATION2Response">
<wsdl:part name="OPERATION2Return" type="xsd:string" />
</wsdl:message>
<wsdl:portType name="WebServiceOne">
<wsdl:operation name="OPERATION1" parameterOrder="INPUT1 INPUT2">
<wsdl:input message="impl:OPERATION1Request"
name="OPERATION1Request" />
<wsdl:output message="impl:OPERATION1Response"
name="OPERATION1Response" />
</wsdl:operation>
<wsdl:operation name="OPERATION2" parameterOrder="INPUT1 INPUT2">
<wsdl:input message="impl:OPERATION2Request"
name="OPERATION2Request" />
<wsdl:output message="impl:OPERATION2Response"
name="OPERATION2Response" />
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="DominoSoapBinding" type="impl:WebServiceOne">
<wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http" />
<wsdl:operation name="OPERATION1">
<wsdlsoap:operation soapAction="" />
<wsdl:input name="OPERATION1Request">
<wsdlsoap:body
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="urn:DefaultNamespace" use="encoded" />
</wsdl:input>
<wsdl:output name="OPERATION1Response">
<wsdlsoap:body
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="urn:DefaultNamespace" use="encoded" />
</wsdl:output>
</wsdl:operation>
<wsdl:operation name="OPERATION2">
<wsdlsoap:operation soapAction="" />
<wsdl:input name="OPERATION2Request">
<wsdlsoap:body
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="urn:DefaultNamespace" use="encoded" />
</wsdl:input>
<wsdl:output name="OPERATION2Response">
LotusScript:
%INCLUDE lsxsd.lss
Dim session As NotesSession
Dim db As NotesDatabase
Class WebServiceOne
Sub NEW
Set session = New NotesSession
Set db = session.GetCurrentDatabase
End Sub
End Class
Java:
import lotus.domino.*;
import lotus.domino.types.*;
LotusScript
() As Single
Java
float[]
WSDL
<complexType name="ArrayOf_xsd_float">
<complexContent>
<restriction base="soapenc:Array">
<attribute ref="soapenc:arrayType"
wsdl:arrayType="xsd:float[]"/>
</restriction>
</complexContent>
</complexType>
WSDL
<complexType name="TwoStrings">
<sequence>
<element name="string1" nillable="true" type="xsd:string" />
<element name="string2" nillable="true" type="xsd:string" />
</sequence>
</complexType>
LotusScript
Note that string1 and string2 must be public.
%INCLUDE "lsxsd.lss"
Class TwoStrings
Sub NEW
End Sub
End Class
Java
public class TwoStrings {
private java.lang.String string1;
private java.lang.String string2;
public TwoStrings() {
}
WSDL
<xsd:simpleType name="vegetableType">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Carrot"/>
<xsd:enumeration value="Lettuce"/>
<xsd:enumeration value="Ketchup"/>
</xsd:restriction>
</xsd:simpleType>
Example 2: Faults
This example shows service method fault handling is the same for both explicit and implicit faults:
...
WS_FAULT base class properties
Call Fault1.setFault(True) required for fault activation
Call Fault1.setFaultString("getQuote InvalidTickerFaultMessage")
optional fault message
End Function
End Class
or even simpler:
public float getStockQuote( java.lang.String tickerSymbol ) throws java.lang.Exception {
...
throw new java.lang.Exception("Thrown exception");
}
Note: Faults for a Java service implementation method appear in the conventional Java throws clause for
the method.
Example 3: Lists
This example illustrates a list of vegetables, consisting of the three items Carrot, Lettuce, and Ketchup.
WSDL
<xsd:simpleType name="listOfVegetables">
<xsd:list itemType="xsd:string"/>
</xsd:simpleType>
Function getListValueAsString (idx As Integer) As String If Not initialized Then Error ErrArgOutOfRange
getListValueAsString = Cstr(value(idx))
End Function
End Class
Note: If the Public value( ) array member type is a mapped simple type class instead of a LotusScript
built-in type, then some pattern statements change accordingly. For example, if the array member type is
XSD_NCNAME, then in Sub setListValueFromString, the last statement:
Set Me.value(idx) = New XSD_NCNAME creates an instance of the simple type class
Call Me.value(idx).setValueFromString(value)
getListValueAsString = value(idx).getValueAsString
There are two types of directives in this file: Property and Rule. The property directive defines a browser
property that can be accessed by @BrowserInfo. The Rule directive specifies a regular expression pattern
which is used to match the browser User-Agent header.
Typically, Web application developers will make use of this file to ensure that their applications work
properly on the Domino Web server. However, because of the files location in the server data directory, it
is likely that the Domino administrator will need to make any necessary modifications.
The following are browser.cnf settings that modify the behavior of the Web engines built-in HTML
generation:
CSSTableTabs - Boolean indicating whether browser can render CSS rules for table tabs
DisableActionBarApplet - Boolean indicating whether browser can handle the ActionBar Applet
DisableViewApplet - Boolean indicating whether browser can handle the View Applet
DisableOutlineApplet - Boolean indicating whether browser can handle the Outline Applet
DisableEditorApplet - Boolean indicating whether browser can handle the Editor Applet DHTMLSections
- String indicating whether / how sections should render using client-side DHTML
Language cross-reference
@BrowserInfo
For more information on how to use the formula language, see the Guidelines chapter, and the A-Z
reference chapters for @Functions and @Commands.
Lexical elements
A formula consists of one or more statements, each consisting of any of the following:
v Variables
v Constants
v Operators
v @Functions
v Keywords
See the applicable sections later in this chapter for descriptions of the statement components.
A value is a variable, a constant, the result of an @function, or the result of an expression formed by
combining any of the foregoing elements with operators.
113
4. SELECT is a reserved word and @All is an @function without arguments. This formula selects all
documents for an operation, for example, for inclusion in a view.
SELECT @All
5. LastName is a variable, + is an operator, , is a constant, and FirstName is a variable. This formula
concatenates LastName, a comma followed by a space, and FirstName.
LastName + ", " + FirstName
Statement separators
Separate multiple statements with semicolons.
FIELD RegionalManager := AreaManager;
FIELD AreaManager := @DeleteField
Spaces
You can place any number of spaces, including none, between operators, punctuation, and values.
However, keywords must be delineated by at least one space, and spaces within text constants are
significant.
In the following statement, at least one space must follow the reserved word SELECT.
SELECT @All
Case
Case is not significant except within text constants. By convention, keywords such as FIELD are
uppercase, and @function and @command names such as ProperCase are mixed uppercase and
lowercase. You need not follow these conventions when typing, but Domino changes the case to conform
to the conventions when saving a formula.
Using variables
Variables are of two types:
v Fields
v Temporary variables
Fields
A formula has access to the fields in the document being processed. The name and type of each field is as
specified in the database design.
Data types
Data types must be correct for the operation or @function being performed. For example, if TotalValue is
a number field, you cannot display it directly with @Prompt because @Prompt requires a text argument.
You must first convert the argument with @Text:
@Prompt([OK]; "Value of MyNumber"; @Text(TotalValue));
Attachments and formatting, except for tabs and spaces, are lost.
You can also use @Abstract to convert rich text fields to plain text as shown below:
plainText := @Abstract([TryFit]; 100; ""; "Body");
Lists
Lists are fields that contain multiple values. Certain @functions and operators deal specifically with lists.
For example, if Locations is a field that allows multiple values, the following statement returns the
number of values in the list:
@Elements(Locations)
Field values
The value of a field is as specified in the document when a formula starts. The formula can modify the
value of a field unless prohibited by access control. You must use the FIELD reserved word to modify a
field -- otherwise, the variable is treated as a temporary variable. The FIELD reserved word can also be
used to create a new field in the current document. The following formula writes a value to the text field
Subject.
FIELD Subject := "No Subject"
Null fields
A null field is equivalent to the text constant (empty quotation marks). The following example tests the
field named Subject in the current document. If the value of Subject is null, it is reset to No Subject.
Otherwise, its value does not change.
FIELD Subject := @If(Subject=""; "No Subject"; Subject)
Since is a text constant, you should avoid its use in non-text fields. In particular, editable non-text
fields should use a default formula to ensure that the field contains a value of the correct type.
Deleting fields
Use @DeleteField to delete a field from a document.
FIELD BodyText := @DeleteField
Form fields
If the form used to create a document is not stored in the document, a field named Form is available and
contains the name of the form. If the form is stored in the document, fields named $TITLE, $Info,
$WindowTitle (if the design specifies a window title), and $Body are available. $TITLE contains the name
of the form. The following example, which works in a button or hotspot, displays the name of the form
used to create the current document.
@Prompt([OK]; "Form"; @If(@IsAvailable(Form); Form; $TITLE))
Choose File - Document Properties, and select Fields to see what fields are in a document.
You can remove a form stored in a document by deleting $TITLE, $Info, $WindowTitle, and $Body. You
must then create a Form field and place in it the name of a form in the database. The following formula,
which works as an agent, removes the form Travel Request stored in the current document and replaces
it with the database form Travel Arrangements.
Temporary variables
A temporary variable exists only within a formula. Its scope is that formula and it has no attributes other
than the ones assigned to it within the formula.
variableName := value
The variable takes the type of the value on the righthand side of the equation. This value can be any of
the field types or boolean.
Boolean data types are returned by certain @functions and have a value of 1 (True) or 0 (False).
Variables with String data types cannot contain more than 2,048 characters. Concatenate multiple
variables to handle larger amounts of text. For example, instead of trying to set the variable Source
equal to a 3,400-character text block, set the variable Source1 equal to the first 1,700-character text block
and Source2 to the second 1,700 characters. Concatenate the variables as follows:
@Prompt([OK];"Length";@Text(@Length((Source1+Source2))))
Using a variable name on the lefthand side of an equation results in a temporary variable unless
preceded by the reserved word FIELD.
The following example makes extensive use of temporary variables to place the name of the current
month in a field named MonthName. The steps are:
1. Place the current date in the temporary variable date.
2. Extract from date and convert to text month, the number of the month.
3. Create a text list nMonths with the values 1 through 12.
4. Create a text list months with the values January through December.
5. Replace the number value of the current month with its name.
date := @Created;
month := @Text(@Month(date));
nMonths := "1" : "2" : "3" : "4" : "5" : "6" : "7" : "8" : "9" : "10" : "11" : "12";
months := "January" : "February" : "March" : "April" : "May" : "June" : "July" : "August" : "September" :
"October" : "November" : "December";
FIELD MonthName := @Replace(month; nMonths; months)
Note: Reassignment of a variable is new with Release 6. In previous releases, an attempt to reassign a
variable resulted in an error.
The following example reassigns the temporary variable n at each iteration of an @While loop.
n := 1;
@While(n <= @Elements(Categories);
@Prompt([OK]; "Category " + @Text(n); Categories[n]);
n := n + 1
)
Text constants
Specify a text constant by enclosing characters, including spaces, numbers, and special characters, in
quotation marks () or braces ({}).
Using braces as text delimiters enables you to enter the text constant Hello World as {Hello World}
instead of \Hello World\.
Do not enter variable names in quotation marks or braces, or the names are treated as text.
Enter numbers in quotation marks or braces when you want them treated as text.
The backslash ( \ ) serves as an escape character in a text constant. To embed quotation marks in a text
constant delimited by quotation marks, precede each embedded quotation mark with a backslash. To
embed a right brace in a text constant delimited by braces, precede each embedded right brace with a
backslash. To embed a backslash in a text constant, type two backslashes.
A compiled formula does not distinguish between quotation marks and braces. When you open a design
element containing formulas, quotation marks delimit all constants including those previously specified
with braces. A backward slash prefixes a quotation mark previously specified in a constant delimited by
braces.
Numeric constants
A numeric constant consists of numeric and special characters, with no intervening spaces, that conform
to the following rules:
v Integer -- The characters 0 - 9 without intervening spaces comprise a positive integer.
v Decimal -- A decimal point may be placed before, after, or within the numeric characters.
v Sign -- The first character of a number may be a plus or minus sign.
v Scientific notation -- A number may be suffixed by the letter E, an optional plus (default) or minus
sign, and an integer.
The table below shows the acceptable formats for entering numbers.
Time-date constants
A time-date constant consists of a time and/or a date enclosed in square brackets formatted as follows:
v 12-hour time -- A time in the format [hh:mm:ss] followed by the letters AM or PM. The hours can
range from 00 to 12. The seconds are optional and default to 00.
v 24-hour time -- A time in the format [hh:mm:ss]. The hours can range from 00 to 23. The seconds are
optional and default to 00.
v Date -- A date in the operating systems default date format. Some examples include:
The year (yyyy) is optional and defaults to the current year. If you use yy to specify a year, in the 20th
century, yy is 50 or greater and in the 21st century, yy is less than 50. The validity of a date format
depends on the date separator that users choose in their operating system control panel. The default
separator for Windows, UNIX, and Macintosh is a slash (/). The default separator for OS/2 is a
hyphen ().
v Time and date -- A time and a date in the format [time date] or [date time].
If time-date values are subtracted, the result is an integer that represents the difference between the times
in seconds.
Tip: Display Time must be selected in the Date/Time field properties box for the time to display. It is not
selected by default.
Notes converts and saves human-readable time zone values using the following time zone attributes:
Attribute Definition
Z Time zone offset from GMT.
DO Daylight Saving Time (DST) observed flag. 1 means DST is in effect; 0 means it is not. If equal
to 1, a value should be supplied for DL.
DL DST law identifying the <StartMonth> <StartWeek> <StartDayOfWeek> <EndMonth>
<EndWeek> <EndDayOfWeek>.
ZX (Optional) Host-specific time zone index.
ZN (Optional) Time zone name.
For example, if you select (GMT -05:00) Eastern Time (US & Canada) from the Time zone drop-down
list, Notes saves the value as:
Z=5$DO=1$DL=4 1 1 10 -1 1$ZX=25$ZN=Eastern
This indicates that the time zone is 5 hours before Greenwich Mean Time (-5). DST is in effect and starts
in the month of April(4), during week 1, on day 1 of the week, which is a Sunday, and ends in
October(10), during the last week (-1), also on a Sunday(1). The ZX and ZN attributes are values used
exclusively by Notes.
If you use a Time zone field as the default value for a view column, it displays as a similar string of
attribute and value pairs. Use @TimeZoneToText to convert the field to a human-readable format.
You can enter these attribute and value pairs as the default value for a Time zone field, or you can let the
@TimeToTextInZone function do the work for you. For example, to display a box specifying the current
time in Alaska, you could create a Hotspot button with this formula:
@Prompt([Ok];"Current time in Alaska";@TimeToTextInZone(@Now;"Z=9$DO=1$DL=4 1 1 10 -1 1"))
Using operators
Operators assign values, modify values, and combine existing values into new values. The following
sections describe:
v Operator overview and precedence
v Order of evaluation
v Assignment operator
v List concatenation operator
v List subscript operator
v Unary operators
v Arithmetic operators
v Text operator
v Comparison operators
v Logical operators
v Operations on lists
- Negative
* Multiplication 4
** Permuted multiplication
/ Division
*/ Permuted division
+ Addition, concatenation 5
*+ Permuted addition
- Subtraction
*- Permuted subtraction
*= Permuted equal
!= Not equal
=! Not equal
| Logical OR
Assignment operator
The assignment operator (:=) assigns a value on the righthand side to a variable on the lefthand side. The
variable assumes the type of the value on the righthand side.
The variable may be preceded by the reserved word DEFAULT, ENVIRONMENT, or FIELD. A variable
not preceded by a reserved word is a temporary variable.
An assignment statement can be nested in an operation. The following example assigns London to the
variable city1 as well as the value LONDON to city1Upper:
city1Upper := @UpperCase(city1 := "London")
This example, when used in a computed for display text field, displays the results of calculating the
hotel, dinner, and nights editable number fields once a user enters their values and refreshes the
document:
all := @Text(nights * each := hotel + dinner);
@If(hotel="";"";"She spent " + @Text(each) + " per night and " + all + " in total on accommodations during
the trip.")
The FIELD reserved word can be used with a nested assignment. For example:
FIELD CityUpper := @UpperCase(FIELD City := "London" )
The DEFAULT and ENVIRONMENT keywords cannot be used with a nested assignment statement.
A subscript consists of a numeric value in brackets. The numeric value can be a constant, variable, or
expression. Decimals are rounded to integers. A subscript follows the list name.
Note that the Categories field containing the list must be located above or to the left of the field
containing this code or the formula returns an Array index out of bounds error.
The first element of a list is subscript [1]. A subscript that is less than [1] or that is greater than the
number of elements in the list also returns the Array index out of bounds error.
The subscript operator is valid for any data type that allows lists (text, number, and date/time) even if
the data entity is scalar. The subscript operator is only valid for data types that do not allow lists
(richtext) when a subscript of [1] is used; this returns its current value unchanged.
The subscript operator cannot be used on the left side of an assignment statement. That is, you cannot
assign a value to a subscripted element. You must build the complete list and then assign it. For example,
if Categories is a 3-element list and you want to assign a new value to element 2:
The values can be constants, variables, and expressions, including other lists.
LNY := "London" : "New York";
LNY : "Tokyo"
Since list concatenation has the highest precedence next to subscripts, list elements that are expressions
must be in parentheses. In the following example, the minus sign has the unintended effect of applying
to both the third and fourth elements of the second list.
1:2:3:4 + 1:2:-3:4 = 2:4:0:0
Use parentheses to make the minus operation apply only to the third element of the second list.
1:2:3:4 + 1:2:(-3):4 = 2:4:0:8
Unary operators
The unary operators (+ and -) specify the sign of a numeric value. An unsigned numeric value is positive.
The following numeric values are equivalent:
5
+5
-(-5)
Arithmetic operators
The arithmetic operators (* / + -) combine two numeric values using multiplication, division, addition,
and subtraction. The following operations all result in the numeric value 16:
4 * 4
64 / 4
12 + 4
20 - 4
Text operator
The text concatenation operator (+) combines two text values. The following operation results in the
value of the variable CompanyName followed by a comma, a space, and Inc.
CompanyName + ", Inc."
Comparison operators
The comparison operators (=, <>, !=, ><, <, >, <=, and >=) compare values of the same type and produce
a logical result (True or False). The following operations all result in a logical value of True:
"London" = "Lon" + "don"
"London" != "Tokyo"
2 + 2 > 3
Logical operators
The logical operators (!, &, and |) combine logical values. The following operations all result in a value
of True. The operations are shown twice, with and without parentheses. The parentheses clarify the order
of evaluation but are unnecessary because the logical operations are lower in precedence than the
surrounding comparison operations.
Operations on lists
Operations on lists are of two types:
v Pair-wise -- Pairwise operators act on two lists in parallelelement fashion. The first element of list 1
pairs with the first element of list 2, the second element of list 1 pairs with the second element of list 2,
and so on. If one list has fewer elements than the other, the last element in the shorter list is repeated
for operations with the remaining elements of the longer list. If list 1 consists of A:B:C and list 2
consists of 1:2, the operation is performed as though list 2 contained 1:2:2. For pairwise
equality tests, only one match is needed for the statement to return True, or 1.
v Permuted -- Permutation operators act on two lists, pairing every possible combination of their values.
The resulting list has an element for each pairing in the following order: list 1 element 1 paired with
each element in list 2, list 1 element 2 paired with each element in list 2, and so on through the last
element in list 1.
If an operation occurs on a list and a non-list value, the non-list value is paired with each element in the
list.
The table below shows how pairwise and permutation operators differ.
A:B:C+1:2 A1:B2:C2
A:B:C+1 A1:B1:C1
Concatenation, permutation A:B:C*+1:2:3 A1:A2:A3:B1:B2:B3:C1:C2:C3
A:B:C*+1:2 A1:A2:B1:B2:C1:C2
1:2:3+10:20 11:22:23
1:2:3+10 11:12:13
Addition, permutation 1:2:3*+10:20:30 11:21:31:12:22:32:13:23:33
1:2:3*+10:20 11:21:12:22:13:23
Text equality, pair-wise A:B:C=B:C:A 0 False
A:B:C=B:C 1 True
B:B:C=B:C 1
Text equality, permutation A:B:C*=B:C:A 1
A:B:C*=B:C 1
B:B:C*=D:E 0
Number equality, pair-wise 1:2:3=2:3:1 0
1:2:3=2:3 1
2:3:3=2:3 1
2:3:3=3:1 0
Number equality, permutation 1:2:3*=2:3:1 1
1:2:3*=2:3 1
1:2:3*=4:5 0
Date equality, pair-wise [1190]:[2290]:[3390]= 1
[3390]:[2290]:[1190] 1
[1190]:[2290]:[3390]= 1
[2290]:[3390]
[2290]:[3390]:[3390]=
[2290]:[3390]
Date equality, permutation [1190]:[2290]:[3390]*= 1
[3390]:[2290]:[1190] 1
[1190]:[2290]:[3390]*= 0
[2290]:[3390]
[1190]:[2290]:[3390]*=
[4490]:[5590]
Syntax
The general format of an @function is:
An @function consists of the name of the @function followed by arguments, if any. The first character of
the name of an @function is always @.
Parenthesis
Enclose @function arguments in parentheses.
@Abs(4)
Multiple arguments
Separate multiple arguments with a semicolon.
@IsCategory("Yes"; "No")
@Middle(Company; 4; 4)
Keyword arguments
Enclose keyword arguments in square brackets. @Abstract, @Command, @PostedCommand, @DocMark,
@GetPortsList, @PickList, @MailSend, @Name, and @Prompt use keyword parameters.
@Prompt([OK]; "Response"; Y)
@Name([CN]; AUTHOR)
@Command([EditClear])
You can also assign a keyword to a variable. For instance, the following assignment is valid:
o := [OK];
@Prompt(o;"Database title";@DbTitle)
Return values
An @function calculates a return value and replaces itself with the value. The use of the @function must
be appropriate for its data type. For example, @Power can compute the value of a numeric field:
Side-effects
A sideeffect is an action that occurs outside the immediate scope of the formula. For example, @Prompt
displays a dialog box in addition to returning a value. Make sure that a side-effect occurs at the correct
point of a formulas execution.
@Function Side-effect
@Command A Notes command, such as opening a database, is performed.
@PostedCommand
@DbColumn @DbCommand Another view or database is accessed, and data is retrieved.
@DbLookup
@DDEInitiate @DDEExecute A DDE conversation is initiated (or terminated), or a DDE statement is executed.
@DDEPoke @DDETerminate
@MailSend A Notes mail memo is created and routed to another user or database.
@Prompt @PickList A dialog box is displayed; data may be returned.
@DialogBox
@Commands
The @Command and @PostedCommand functions execute a Notes command. The first argument to
@Command or @PostedCommand is a keyword argument that specifies the Notes command. Depending
on the Notes command, other arguments may be required.
You must use @PostedCommand in applications that run in Notes R3 and R4. The difference between
@Command and @PostedCommand is the order of evaluation.
Because of their large number and special status, these @functions comprise a separate category called
@commands. Each @command is named after the first argument to @Command or @PostedCommand,
which is a keyword argument.
You must be careful with @commands due to their side-effects and their order of evaluation.
See Order of evaluation for formula statements and Side-effects in this chapter for additional
information.
You can use @commands in formulas for tools, events, button hotspots, action hotspots, and actions. You
can use @commands in agents that have no target documents. See the individual @command descriptions
for further restrictions.
Setting the NoExternalApps environment variable to 1 disables any formula containing an @command
function. The user does not receive an error message -- the formula simply does not execute.
Except for @commands, the formula language operates on back-end Notes objects. For example, a field
named in a formula refers to the field as it exists in storage and the FIELD reserved word modifies a
stored field. @Commands operate in the user interface; changes made there are not reflected in the
back-end until a document is saved. You cannot intersperse back-end and user interface accesses of the
same document and get correct results.
Evaluation of @commands
Execution of an @PostedCommand function occurs after all other @functions in the formula. For instance,
look at the following formula:
@PostedCommand([CommandName]; Argument);
@If(Condition; TrueStatement; FalseStatement);
FIELD X := "Text"
Execution of an @command function occurs in the order it appears with some exceptions. The exceptions,
like @PostedCommands, execute at the end of the formula. Each exception has an equivalent @command
that executes immediately.
The following table lists the @commands that execute last and their corresponding @commands that
execute immediately.
Note: The functions that get evaluated immediately are new with Release 6.
@If function
@If executes one statement or another depending on whether a logical value is True or False:
@If(LogicalValue; TrueStatement; FalseStatement)
@Do function
@Do executes a number of statements in sequence and can be used as an execution path within an @If
function:
@If(LogicalValue; @Do(TrueStatement1; TrueStatement2); FalseStatement)
Any @Command functions within an @Do function are executed in order after all other @functions, both
within and without the @Do function, are executed.
@Return function
@Return stops execution of the formula:
@If(LogicalValue; @Return(""); "")
REM [{remarks}]
SELECT logicalValue Specifies whether or not the current document is valid for processing
in view selection, replication, and agent formulas.
A reserved word is always the first word in a statement. By convention, reserved words are entered in
uppercase. You can enter them in lowercase, but Lotus Domino converts them to uppercase when saving
a formula.
The fieldName and variable specifications to reserved words are names, not text constants. Do not enclose
them in parentheses.
The following formula demonstrates how to enter the view name _Marketing\_Procedures:
@Command([SwitchView]; "Marketing\\Procedures")
Debugging formulas
The formula language does not provide a formal debugging mechanism. You can use @Prompt to stop at
certain points and to examine variables. This example uses @Prompt to set a checkpoint and then to
examine a variable. After you establish that your code is running correctly, remove the debug statements.
@Prompt([OK]; "Checkpoint"; "About to calculate LastName");
LastName := @RightBack(@Left(@UserName; "/"); " ");
@Prompt([OK]; "Value of LastName"; LastName)
Alternatively, you can design debug fields into the form for the documents your formula processes. Your
formula loads the debug fields during testing and you open the documents processed to examine the
fields. After testing, remove the debug fields from the form as well as the debug statements from the
formula.
FIELD DebugLastName := lastName
See Formula Language @Functions A-Z and Formula Language @Commands A-Z for a reference.
Formulas
A formula consists of one or more statements that are executed in order. Depending on the object
associated with the formula and other criteria, the formula may execute once or it may execute multiple
times on selected documents (one execution per document).
Agent formulas execute multiple times on selected documents, giving the effect of conditional, iterative
execution. Data can be processed in lists, giving the same effect.
You can:
v Write formulas that evaluate to a result
v Write formulas that perform actions
v Work with lists
v Use conditional statements
v Use iterative statements
133
v Column formula -- Must evaluate to a value that can be converted to a text string.
v Hide action formula -- Must evaluate to True (1) or False (0).
v Formula pop-up -- Must evaluate to a text string.
v Window title formula -- Must evaluate to a text or numeric value, except that the formula can consist
of a single field of any type.
v Section access formula -- Must evaluate to a name or list of names.
v Insert subform formula -- Must evaluate to a text value that is the name of a subform.
v Section title formula -- Must evaluate to a text or numeric value, except that the formula can consist of
a single field of any type.
v Hidden paragraph formula -- Must evaluate to True (1) or False (0).
v Default value formula -- Must evaluate to a value suitable for storage in the current field.
v Input translation formula -- Must evaluate to a value suitable for storage in the current field.
v Default validation formula -- Must evaluate to success (1) or failure (0).
v Computed field formula -- Must evaluate to a value suitable for storage in the current field.
v Keyword field formula -- Must evaluate to a value or list of values suitable for storage in the current
field.
These formulas may be as simple as a single field, constant, or @function, or may contain multiple
statements, use temporary variables, modify fields, and produce side-effects. In all cases, however, their
final statement must be a value suitable for the result.
The reserved word SELECT is prepended to the logical statement that terminates a replication or
selection formula if SELECT is not explicitly specified. These formulas run against every document in the
database (replication formula) or view (selection formula) to determine their inclusion or exclusion in the
replication process or the view. The @All function returns the value True, so the formula SELECT @All
includes all documents.
Lists provide limited iteration because a list operation applies the operation to each element of the list,
like processing an array in a loop.
Function Description
@Compare Compares two lists pair-wise.
@Count(list) Determines the number of elements in a list, returning 1 if the
value it is evaluating is a null string or not a list.
@Elements(list) Determines the number of elements in a list, returning 0 if the
value it is evaluating is a null string or not a list.
@Explode(string) Converts a text string into a text list. Spaces, commas,
semicolons, and newlines separate elements in the string.
@Explode(string ; separators) Converts a text string into a text list; the second parameter
specifies the separators (except newlines) for elements in the
string.
@Explode(string ; separators ; includeEmpties) Converts a text string into a text list; @True as the third
parameter includes empty list elements where consecutive
separators occur.
@Explode(string ; separators ; includeEmpties ; Converts a text string into a text list; @False as the fourth
newlineAsSeparator) parameter excludes newlines as separators.
The @If statement has an odd number of parameters with a minimum of three, as follows:
v The condition is the first parameter and every other parameter thereafter if the @If statement has
multiple conditions.
v The statement that is executed if the condition is True is the second parameter and every other
parameter thereafter if the @If statement has multiple conditions.
v The statement that is executed if the condition is False is the last parameter.
The @If function is evaluated left to right, and the first condition that is True causes its corresponding
True statement (that is, the next parameter) to be processed. No further evaluation or processing within
the @If statement takes place. If none of the conditions are True, the False statement (that is, the last
parameter) is processed.
The True and False statements take various forms, depending on their context:
v If the @If statement is the last statement in a formula that evaluates to a result, the True and False
statements must evaluate to a result.
v If the @If statement is the righthand side of an assignment, the True and False statements must
evaluate to a value suitable to assignment to the field or temporary variable on the left side.
v Otherwise, the True and False statements must cause an action.
The parameters of @If can themselves be @If statements. Nested @If statements are useful to work
around the limited logic constructs in the formula language, but make for complicated syntax.
The @Do function provides a means to execute multiple statements on a True or False condition.
For more information on conditional operators, see Using operators in Formula Language Rules.
Non-text values must be converted with @Text to be used as @Prompt and @PickList parameters. The
text values can be constants, temporary variables, fields, or expressions.
@DialogBox does not transfer rich text fields. These should not be included in your design.
The form that is displayed in the dialog box is best created using a layout region, and @DialogBox should
use the [AutoVertFit] and [AutoHorzFit] options.
Environment values are text. Non-text values must be converted before being set and after being
retrieved.
User environment variables are prepended with the $ character. If you add an environment variable with
an editor or LotusScript, for example, and want to retrieve it with @Environment, the first character must
be $.
Be sure you know which notes.ini file is affected by your formula. If the formula is in a database on a
server, the formula runs on the server in the following cases: replication formula, agent for which the
trigger is After new mail has arrived or On schedule, selection formula, or column formula.
Otherwise, the formula runs on the users workstation. Replica copies access different NOTES.INI files,
depending on which server or workstation contains the replica copy. Server access is subject to
administrative restrictions.
Handling errors
Errors are of two types:
v Syntax errors are reported when you check or attempt to exit the formula you are writing.
v Run-time errors occur when the formula runs.
Syntax errors
Syntax errors are reported when you either check or attempt to exit the formula you are writing. You
receive a message specifying the error, and the line containing the error is highlighted. You must
determine and then correct the error before proceeding. Common syntax errors include the following:
v Incorrectly spelled @function name or reserved word
v Missing or excessive parentheses
v Missing quotation mark on a string constant
v No semicolon between statements
You should write a formula a little at a time and check it often as you go along. Formula syntax tends to
be complex, due to nesting.
Run-time errors
Run-time errors occur when the formula runs. These errors can be categorized as follows:
v Unexpected -- These are development errors that your users should never see. For example, if you
forget an @function parameter, the following message appears at run-time: Insufficient arguments for
@function. You should test your formula and attempt to correct all unexpected errors.
v Unreported -- These are results that are incorrect but are not reported as errors. For example, if you try
to display a numeric value with @Prompt, @Prompt works but displays a blank. Again, your user
should never see these errors. You should test your formula and ensure that all results are as expected.
v Expected -- These are errors that the user might cause at run-time. For example, if you prompt for the
name of a database, the user might enter the name of a nonexistent database. You cannot prevent these
errors, but you can anticipate and test for them in the formula and take appropriate actions.
Notes generates an error for a field if the built-in validation checking fails. For example, if you specify a
field as numeric and the user enters a non-numeric value, Lotus Domino makes the value of the field an
error. You can generate an error for a field by setting its value to @Error.
Notes reports errors in fields when the user attempts to save the document. For example, if a numeric
field contains a non-numeric value, Lotus Domino generates the message Cannot convert text to a
number when the user attempts to save a document.
To change the message or perform another action when an error occurs, test the field for an error with
@IsError in the field validation formula. You can generate your own error message with @Failure, but
only in field validation formulas.
To incorporate your own error conditions for a field, return @Error if you detect an error condition.
Outside field formulas, for example, in an agent, button, or hotspot, you can check the contents of a field
and react immediately to an error condition. For example, if you check a field with a button, you can
change the field value or report the error before the user attempts to save the document. In checking for
errors, be aware that the built-in validation checking generates an error as soon as the user enters a value
in a field, but that a translation formula using @Error does not generate an error until the user attempts
to save the document.
Most @functions can be used in formulas for any Notes object, but some @functions are restricted in their
applicability. The following table lists the @functions that are restricted and lists the Notes objects in
which they can be used effectively. In addition, for an @function to return information on the current
database, view, document, or field, these objects must be current.
The name of the @function is @Command or @PostedCommand. The first argument is the name of the
@command enclosed in brackets. The remaining arguments are the arguments to the @command.
You can use @commands in formulas for toolbar buttons, agents that do not specify target documents,
events, button hotspots, and action hotspots. You cannot use @commands in a formula that does not
interact with the user. These include replication, form, selection, column, hide action, window title,
section title, section access, insert subform, hidden paragraph, default value, input translation, input
validation, computed value, and keyword field formulas, and agents other than those that specify no
target documents.
You cannot use most @commands in Web applications, since @commands are based on the Notes
workstation user interface. About 30 @commands are supported but some behave differently. See
Programming Domino for Web Applications, Formula language.
@Command functions execute in sequence with other @functions, with some exceptions. For example, the
following formula executes the @command first:
@PostedCommand functions execute in sequence with each other after all other @functions execute. This
emulates the behavior of @Command in Notes R3. For example, the following formula executes the
@command last:
@PostedCommand([EditDocument]; "1");
@Prompt([Ok]; "Edit mode"; "The document will go into Edit mode.")
For additional information, see Order of evaluation for formula statements in the Formula Language
Rules chapter.
You can check and respond to the return value of @Command (but not @PostedCommand). The return
value is @True if the @command succeeds and @False if it fails. The following toolbar button formula
returns if the FileOpenDatabase @command fails.
@If(@Command([FileOpenDatabase]; "NEWSUBJ"); ""; @Return(""));
@Command([Compose]; ""; "Main Topic");
@Command([EditGotoField]; "Subject");
@Command([EditInsertText]; "New subject");
@Command([EditGotoField]; "Body")
Function Description
@Char(number) Converts an IBM Code Page 850 code number to its
corresponding character.
@IsNumber(value) Returns True (1) if a value is a number or number list.
@IsText(value) Returns True (1) if a value is a text string or text string list.
@IsTime(value) Returns True (1) if a value is a time-date or time-date list.
@Text(value) Converts a value to a text string.
@Text(value ; format) Converts a numeric or date-time value to a text string according
to a specified format.
@TextToNumber(string) Converts a text string to a number.
@TextToTime(string) Converts a text string to a date-time value.
@TimeToTextInZone(date-time ; time zone) Converts a date-time value to a string that includes time zone
information.
@TimeZoneToText( time zone) Converts a time zone value to a human-readable string.
@ToNumber(string or value) Converts a number or text string to a number.
@ToTime(string or date-time value) Converts a number or date-time value to a date-time value.
Function Description
@Begins(string ; sub) Determines whether a string begins with a substring.
@Contains(string ; sub) Determines whether a string contains a substring.
@Contains(string; list) Determines whether a string contains any substring in a list.
@Ends(string ; sub) Determines whether a string ends with a substring.
@FileDir(pathname) Extracts the directory part of a file path name.
@Left(string ; n) Extracts the leftmost n characters from a string.
@Left(string ; sub) Extracts the leftmost characters from a string up to a substring,
searching left to right.
@LeftBack (string ; n) Extracts the leftmost characters from a string up to the nth
character from the right.
@LeftBack(string ; sub) Extracts the leftmost characters from a string up to a substring,
searching right to left.
@Middle(string ; off ; n) Extracts n characters from a string starting at an offset, searching
left to right.
@Middle(string ; sub ; n) Extracts n characters from a string starting at a substring,
searching left to right.
@Middle(string ; off ; sub) Extracts characters from a string starting at an offset and stopping
at a substring, searching left to right.
@Middle(string ; sub ; sub) Extracts characters from a string starting and stopping at
substrings, searching left to right.
@MiddleBack(str ; off ; n) Extracts n characters from a string starting at an offset, searching
right to left.
@MiddleBack(str ; sub ; n) Extracts n characters from a string starting at a substring,
searching right to left.
@MiddleBack(str ; off ; sub) Extracts characters from a string starting at an offset and stopping
at a substring, searching right to left.
@MiddleBack(str ; sub ; sub) Extracts characters from a string starting and stopping at
substrings, searching right to left.
@ReplaceSubstring(source ; from ; to) Replaces from with to in source. If from and to are lists,
replaces corresponding entries in order.
@Right(string ; n) Extracts the rightmost n characters from a string.
Function Description
@LowerCase(string) Converts all uppercase characters in a string to lowercase.
@NewLine Inserts a new line (carriage return) into a text string.
@ProperCase Converts the first character of each word in a string to uppercase
and the remaining characters to lowercase.
@Repeat(string , number) Repeats a string a number of times.
@Trim(string) Removes leading, trailing, and redundant spaces from a string.
@Trim(list) Removes leading, trailing, and redundant spaces from each
element of a string list, and removes blank elements from the list.
@UpperCase(string) Converts all lowercase characters in a string to uppercase.
Function Description
@Abs(number) Calculates the absolute (unsigned) value of a number.
@ACos(cosine) Calculates the arc (inverse) cosine of a cosine.
@ASin(sine) Calculates the arc (inverse) sine of a sine.
@ATan(tangent) Calculates the arc (inverse) tangent of a tangent.
@ATan2(x; y) Calculates the arc (inverse) tangent using the tangent y/x of an
angle.
@Cos(angle) Calculates the cosine of an angle (in radians).
@Exp(number) Calculates e raised to the power of a number.
@FloatEq(number ; number ; range) Compares two numbers for equality within a confidence range.
@Integer(number) Truncates a number to an integer.
@Integer(numlist) Truncates the elements of a number list to integers.
@Log(number) Calculates the common (base 10) logarithm of a number.
@Ln(number) Calculates the natural (base e) logarithm of a number.
@Max(number ; number) Calculates the larger of two numbers.
@Max(numlist ; numlist) In a pairwise list operation, calculates the larger of two
numbers.
@Max(numlist) Calculates the largest number in a list.
@Min(number ; number) Calculates the smaller of two numbers.
@Min(numlist ; numlist) In a pairwise list operation, calculates the smaller of two
numbers.
@Min(numlist) Calculates the smallest number in a list.
@Modulo(number ; number) Calculates the remainder of a number divided by a second
number.
@Modulo(numlist ; numlist) In a pairwise list operation, calculates the remainder of a
number divided by a second number.
@Pi Calculates the value of Pi.
@Power(base ; exp) Calculates the value of a base raised to the power of an
exponent.
@Random Returns a random number in the range 0 to 1, inclusive.
@Round(number) Rounds a number to the nearest integer.
@Round(number ; factor) Rounds a number to the nearest specified factor.
@Round(numlist) Rounds each number in a list to the nearest integer.
@Round(numlist ; factor) Rounds each number in a list to the nearest specified factor.
@Sign (number) Returns 1 for a positive number, -1 for a negative number, and
0 for zero.
@Sin(angle) Calculates the sine of an angle (in radians).
@Sqrt (number) Calculates the square root of a number.
@Sum(num; num; ...) Calculates the sum of numbers and number lists.
@Tan(angle) Calculates the tangent of an angle (in radians).
A time-date constant is a date, a time, or both, in brackets. The date is the month, day, and year
separated by a slash (/) or a hyphen (-) for OS/2. Year is optional and defaults to the current year; a
2-digit year means the 20th century if 50 or greater, and the 21st century if less than 50.
Dates can be compared and subtracted. Subtraction yields a numeric value representing seconds. To
measure the difference between two dates in days, divide the result by 86,400, which is the number of
seconds in a day. For example, if you have two date fields, date1 containing [07/01/01] and date2
containing [07/05/01], the following returns 345,600:
date2-date1
To display the result as 4 days instead of 345,600 seconds, use the following code:
(date2-date1)/86,400
Function Description
@Accessed Returns the time-date the document was last accessed.
@Adjust(time-date; y; m; d; h; m; s) Adjusts a time-date by the negative or positive values of the
remaining parameters.
@BusinessDays Returns the number of business days in one or more date ranges.
@Created Returns the time-date the document was created.
@Date(y; m; d) Returns the date for year, month, and day.
@Date(y; m; d; h; m; s) Returns the date for year, month, day, hour, minute, and second.
@Date(time-date) Returns the date for a time-date.
@Day(time-date) Extracts the day of the month from a time-date.
@Hour(time-date) Extracts the hour from a time-date.
@Minute(time-date) Extracts the minute from a time-date.
@Modified Returns the time-date the document was last edited and saved.
@Month(time-date) Extracts the month from a time-date as 1-12.
@Now Returns the current time-date.
@Now([ServerTime]) Returns the current time-date for the server containing the current
database.
@Now([ServerTime]; serverNames ) Returns the current time-date for specified servers.
@Second(time-date) Extracts the seconds from a time-date.
@Time(y; m; d) Returns the time for year, month, and day.
@Time(y; m; d; h; m; s) Returns the time for year, month, day, hour, minute, and second.
@Time(time-date) Returns the time for a time-date.
@Today Returns todays date.
@Tomorrow Returns tomorrows date.
@Weekday(time-date) Returns the day of the week for a time-date as 1-7 (Sunday through
Saturday).
@Year(time-date) Extracts the year from a time-date.
@Yesterday Returns yesterdays date.
@Zone Returns the time zone setting of the current computer.
User names can be either distinguished or non-distinguished, and distinguished names can be canonical
or abbreviated. Use @Name to change the form of a user name.
Function Description
@Domain Returns the name of the users Lotus Notes/Domino mail domain.
@MailDbName Returns the server name and path name for the users mail database. This
@function evaluates to a 2-member list.
@Name([key]; name) Changes the form of a user name. The keywords include [CN] to extract the
common name from a distinguished name, [Abbreviate] to abbreviate a
distinguished name in canonical form, [Canonicalize] to do the reverse, and
[ToKeyword] to put the name components in reverse order separated by
backslashes (for categorized views).
@OptimizeMailAddress(address) Removes unnecessary domains from an address.
@Password(string) Encodes a string. You cannot determine the original string from the encoded
result.
@Platform Returns the platform that the user is running on: Macintosh, NetWare,
OS2V1, OS2V2, UNIX, Windows/16, or Windows/32.
@StatusBar Writes a message or messages to the status bar.
@UserAccess Given a server and file name, indicates the users level of access to the
database.
@UserNamesList Returns a text list containing the users common name, hierarchical names,
ACL roles (if any), and if the database is on a server, any groups the user
belongs to.
@UserPrivileges Returns a text list of the users privileges.
@UserRoles For databases on servers, returns a list of roles for the current user.
@Version Returns (as a string) the version of Notes that is running.
Function Description
@DbManager Returns the users, groups, and servers that currently have manager access to
the database. Returns a list.
@DbName Returns the names of the current Domino server and database. Returns a
2-element list.
@DbTitle Returns the title of the current database.
@ReplicaID Returns the replica ID of the current database
@ServerName Returns the name of the server containing the current database.
@ViewTitle Returns the title of the current view.
These @functions work only in Window Title and Column formulas, and some, as noted, are restricted to
either one or the other. The return value in every case is a string.
For details on more advanced formulas for columns, see Advanced options for columns in the
Application Development in Domino Designer book.
Function Description
@DocChildren Returns the number of immediate children of the current document.
@DocChildren(def) As above, but returns def. Use % in def to represent the number.
@DocChildren(zero; def) As above, but returns zero if there are no children.
@DocChildren(one, zero; def) As above, but returns one if there is one child.
@DocDescendants Returns the number of descendants, including children and children of
children, of the current document.
@DocDescendants(def) As above, but returns def. Use % in def to represent the number.
@DocDescendants(zero; def) As above, but returns zero if there are no descendants.
@DocDescendants(one, zero; def) As above, but returns one if there is one descendant.
@DocLevel Returns the level of the current document in the current view.
@DocNumber Returns the number of the current document or category within the current
view.
@DocNumber(sep) As above, but separates the components of the number with sep rather than
a period.
To read from a field in the current document, name the field or use the @GetField function, which returns
the value of the field whose name you specify. When you specify a field name, case does not matter, but
the name must exactly match the field name. This function returns null if the value of the specified field
is null or the specified field does not exist.
To write to a field in the current document, you must use the FIELD reserved word or the @SetField
function. You cannot simply name the field.
v The FIELD reserved word is used in an assignment statement and has the following format. If you
omit the FIELD reserved word, the assigned variable is treated as a temporary variable.
FIELD field-name := expression
The DEFAULT reserved word provides a value in the event that a field is not in the document. If the
field is available, its value is used. If the field is unavailable, the DEFAULT value is used.
DEFAULT field-name := expression
The @MailSend function mails a document. @MailSend without parameters mails the current document,
which must contain a field named SendTo containing the recipients. @MailSend with parameters
constructs the document to be mailed from the parameters.
@MailSend
@MailSend( to; cc; bcc; subject; body; fields; flags )
The @DeleteField function deletes a field. You specify it as the expression in a FIELD assignment.
FIELD field-name := @DeleteField
The@DocMark([NoUpdate]) function prevents formula changes to the document from being written to
storage. The document is the same after processing by the formula as before. This @function only affects
agents.
This table lists @functions that return document and field attributes.
Function Description
@AllChildren Selects immediate responses to matched documents; use
only in a selection formula.
@AllDescendants Selects all responses to matched documents; use only in a
selection formula.
@AttachmentLengths Returns the size in bytes of each attachment.
@AttachmentModifiedTimes Returns the date on which the file attached to the current
document was last modified.
@AttachmentNames Returns the file names of all attached files.
@Attachments Returns the number of attached files.
@Author Returns the abbreviated names of all authors.
@DocFields Returns the names of all the fields in the document.
@DocLength Returns the size in bytes of the document.
@DocumentUniqueID Returns the documents unique ID, which is unique across
all replicas of the document; in a field, creates a doclink to
the current document.
@GetFocusTable Returns the name, current row, or current column of the
table that is in focus.
@InheritedDocumentUniqueID Returns the unique ID of the parent document; in a field,
creates a doclink to the current document.
@IsAvailable(field) Returns True (1) if a field exists in the document.
@IsDocBeingEdited Returns True (1) if the document is in Edit mode.
@IsDocBeingLoaded Returns True (1) if the document is being loaded.
The first three parameters are the same for both functions:
v Notes : NoCache specifies that the operation is on a Domino database and is not cached. You can
specify for the first list element because Notes is the default. If the data is stable and/or you are
accessing the database many times, you can specify the second list element as to not use a cache.
You can specify the entire parameter as to mean a Notes database and a cache. If you specify a
cache, you can specify ReCache on subsequent lookups to the same data source to refresh the cache.
v server : database specifies the server and database you are accessing. Specify the first list element as to
mean the local Domino directory. Specify the entire parameter as to mean the current database. You
can specify the entire parameter as the replica ID of a database. Notes will search locally and on
servers, and use the first replica it finds. Get the replica ID by choosing File - Database - Design
Synopsis, Replication.
v view specifies the view through which to access the database.
For @DbLookup, the fourth parameter is the key, the value to search for in the first sorted column in the
view. @DbLookup finds every document that matches the key value. Specify [PartialMatch] in the sixth
parameter to match the key against the beginning characters of the column value rather than the entire
column value.
For @DbColumn, the fourth parameter is the number of a column. @DbColumn returns a list of all values
in the column.
The following @functions get and set field values in another document in the current database. However,
you must know the unique ID of the document.
v @GetDocField(unid; fieldName) gets the value of a field given its unique ID.
v @SetDocField(unid; fieldName; value) sets the value of a field given its unique ID.
These functions are suited to accessing and setting values in the parent of a response document, since the
unique ID of the parent is in the $Ref field of the child. In documents that have Formulas inherit values
from selected document set, you can use @InheritedDocumentUniqueID as the formula in a hidden field
in the base document, then use that field name as the formula in a hidden field in the inherited
document. Otherwise, you must devise a scheme for storing and retrieving the unique IDs of the
documents that you want to access.
The following @functions get and set field values in one or more profile documents in the current
database. Profile documents are hidden documents used to store information that can then be shared
across the database. You can create one profile document per user or one profile document for the entire
database.
@GetProfileField retrieves a field from a profile document and caches the fields value for the remainder
of the session.
@DbColumn and @DbLookup can only retrieve data. They cant add, delete, or modify data, or perform
other operations. @DbCommand can retrieve data or send other SQL statements that can change data.
LotusScript provides a wider range of capabilities, including the ability to update the external database.
The first four parameters are the same for all three @functions and establish access to the database
through ODBC. The parameters are:
v ODBC as a string constant; or ODBC : NoCache
v Name of the data source as defined in the table of data sources (odbc.ini in Windows)
v User ID, list of two user IDs, or a null string, depending on the external data source
v Password, list of two passwords, or a null string, depending on the external data source
v (@DbColumn and @DbLookup) Name of the table to be accessed
v (@DbCommand) Command string to be executed
v (@DbColumn and @DbLookup) Name of the column to be accessed
v Option for handling null data returned by the data source
v (@DbLookup) Name of the column containing the key
v (@DbLookup) Value of the key as the appropriate data type, or a list
v (@DbColumn and @DbLookup) List of two elements: Distinct as a string argument or null string;
Ascending or Descending as a string argument
Where user IDs and passwords are required, you can specify null strings and let the user supply them
when the @function executes.
To find the context in which a particular @function works, see the following topics:
v Where does this @function work (Part 1)
v Where does this @function work (Part 2)
For information on ECL security in the formula language, see the listing of @Functions with ECL security.
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 2).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Note that some @functions return different values when the formula runs on a server.
Agent
Toolbar mail
Agent paste Agent Hide- Section
button Selection Column manual modify scheduled when editor
@Abs X X X X X X X X
167
Agent
Toolbar mail
Agent paste Agent Hide- Section
button Selection Column manual modify scheduled when editor
@Abstract X X X X
@Accessed X X X X X X X
@ACos X X X X X X X X
@AddToFolder X X X X
@Adjust X X X X X X X X
@AdminECLIsLocked X X X
@All X X X X X X X X
@AllChildren X
@AllDescendants X
@Ascii X X X X X X X X
@ASin X X X X X X X X
@ATan X X X X X X X X
@ATan2 X X X X X X X X
@AttachmentLengths X X X X X X X X
@AttachmentModifiedTimes X X X X X
@AttachmentNames X X X X X X X
@Attachments X X X X X X X X
@Author X X X X X X X X
@Begins X X X X X X X X
@BrowserInfo X X X
@BusinessDays X X X X X X X
@Certificate X
@Char X X X X X X X X
@CheckAlarms X X X X X
@CheckFormulaSyntax X X X X X X
@ClientType X X X X X
@Command X X X
@Compare X X X X X X X X
@ConfigFile X X X X X X
@Contains X X X X X X X X
@Cos X X X X X X X X
@Count X X X X X X X X
@Created X X X X X X X X
@Date X X X X X X X X
@Day X X X X X X X X
@DB2Schema X X X X X X X X
@DbColumn (Domino) X X X X X X
@DbColumn (ODBC) X X X X
@DbCommand (ODBC) X X X X X X
@DbExists X X X X X
@DbLookup (Domino) X X X X X X
@DbLookup (ODBC) X X X X
@DbManager X X X X X X
@DbName X X X X X X X X
@DbTitle X X X X X X X X
@DDEExecute X X X X X X
@DDEInitiate X X X X
@DDEPoke X X X X
@DDETerminate X X X X
DEFAULT X X X X X X X X
@DeleteDocument X X X
@DeleteField X X X X X X
@DialogBox X X X X X
@Do X X X X X X
@DocChildren X
@DocDescendants X
@DocFields X X X X X X
@DocLength X X X X X X X X
@DocLevel X
@DocLock X X X X X X
@DocMark X X X
@DocNumber X
@DocOmittedLength X X X X X X X X
@DocParentNumber X
@DocSiblings X
@DocumentUniqueID X X X X X X X X
@Domain X X X X X X X X
@DoWhile X X X X
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 2).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Note that some @functions return different values when the formula runs on a server.
Agent
Toolbar mail
Agent paste Agent Hide- Section
button Selection Column manual modify scheduled when editor
@EditECL X X X X
@EditUserECL X X X X
@Elements X X X X X X X X
@EnableAlarms X X X X
@Ends X X X X X X X X
ENVIRONMENT X X X X X
@Environment X X X X X X
@Error X X X X X X X X
@Eval X X X X X X X X
@Exp X X X X X X X X
@Explode X X X X X X X X
@Failure X X
@False X X X X X X X X
FIELD X X X X X
@FileDir X X X X X X X X
@FloatEq X X X X X X X
@FontList X X X X
@For X X X X
@FormLanguage X
@GetAddressBooks X X X X X X
@GetCurrentTimeZone X X X X X X X X
@GetDocField X X X X X X
@GetField X X X X X X X
@GetFocusTable
@GetHTTPHeader X X
@GetIMContactListGroupNames X X X X X X X X
@GetPortsList X X X X X X X X
@GetProfileField X X X X
@GetViewInfo X X X X
@HardDeleteDocument X X X
@HashPassword X X X X X X X X
@Hour X X X X X X X X
@If X X X X X X X X
@IfError X X X X X X X X
@Implode X X X X X X X X
@InheritedDocumentUniqueID X X X X X X X X
@Integer X X X X X X X X
@IsAgentEnabled X X X X X X
@IsAppInstalled X X X X X X
@IsAvailable X X X X X X X X
@IsCategory X
@IsDB2 X X X X X X X X
@IsDocBeingEdited X X X
@IsDocBeingLoaded X
@IsDocBeingMailed X X X
@IsDocBeingRecalculated X X X
@IsDocBeingSaved X X X
@IsDocTruncated X X X X X X X X
@IsEmbeddedInsideWCT X X X X X
@IsError X X X X X X X X
@IsExpandable X
@IsMember X X X X X X X X
@IsModalHelp X X X X X X X X
@IsNewDoc X X X
@IsNotMember X X X X X X X X
@IsNull X X X X X X X X
@IsNumber X X X X X X X X
@IsResponseDoc X X X X X X X X
@IsText X X X X X X X X
@IsTime X X X X X X X X
@IsUnavailable X X X X X X X X
@IsValid X X X X
@IsVirtualizedDirectory X X X X X X X X
@Keywords X X X X X X X X
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 2).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Note that some @functions return different values when the formula runs on a server.
Agent
Toobar mail
Agent paste Agent Hide- Section
button Selection Column manual modify scheduled when editor
@LanguagePreference X X X X X X X X
@LaunchApp X X
@LDAPServer X X X X X X X X
@Left X X X X X X X X
@LeftBack X X X X X X X X
@Length X X X X X X X X
@Like X X X X X X X X
@Ln X X X X X X X X
@Locale X X X X X X X X
@Log X X X X X X X X
@LowerCase X X X X X X X X
@MailDbName X X X X X X X X
@MailEncryptSavedPreference X X X X X X
@MailEncryptSentPreference X X X X X X
@MailSavePreference X X X X X X
@MailSend X X X X X
@MailSignPreference X X X X X X
@Matches X X X X X X X X
@Max X X X X X X X X
@Member X X X X X X X X
@Middle X X X X X X X X
@MiddleBack X X X X X X X X
@Min X X X X X X X X
@Minute X X X X X X X X
@Modified X X X X X
@Modulo X X X X X X X X
@Month X X X X X X X X
@Name X X X X X X X X
@NameLookup X X X X X X
@Narrow X X X X X X X X
@NewLine X X X X X
@No X X X X X X X X
@NoteID X X X X X X X X
@Nothing X X X X
@Now X X X X X X X X
@OptimizeMailAddress X X X X X X
@OrgDir X X X X X X X X
@Password X X X X X X X X
@PasswordQuality X X X X X X X X
@Pi X X X X X X X X
@PickList X X X X
@Platform X X X X X X X X
@PolicyIsFieldLocked X X X X X X
@PostedCommand X X X
@Power X X X X X X X X
@Prompt X X X* X
@ProperCase X X X X X X X X
@Random X X X X X X X X
@RefreshECL X X X X
@RegQueryValue X X X X X X
REM X X X X X X X X
@Repeat X X X X X X X X
@Replace X X X X X X X X
@ReplaceSubstring X X X X X X X X
@ReplicaID X X X X X X X
@Responses
@Return X X X X X X X X
@Right X X X X X X X X
@RightBack X X X X X X X X
@Round X X X X X X X X
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 2).
Note that some @functions return different values when the formula runs on a server.
Agent
Toolbar mail
Agent paste Agent Hide- Section
button Selection Column manual modify scheduled when editor
@Second X X X X X X X X
SELECT X X X X
@Select X X X X X X X X
@ServerAccess X X X X X X X X
@ServerName X X X X X X X X
@Set X X X X X X X X
@SetDocField X X X X X X
@SetEnvironment X X X X X X
@SetField X X X X X
@SetHTTPHeader
@SetProfileField X X X X X
@SetTargetFrame X X
@SetViewInfo X X
@Sign X X X X X X X X
@Sin X X X X X X X X
@Sort X X X X X X X X
@Soundex X
@Sqrt X X X X X X X X
@StatusBar X
@Subset X X X X X X X X
@Success X X
@Sum X X X X X X X X
@Tan X X X X X X X X
@TemplateVersion X X X X X X X X
@Text X X X X X X X X
@TextToNumber X X X X X X X X
@TextToTime X X X X X X X X
@ThisName
@ThisValue
@Time X X X X X X X X
@TimeMerge X X X X X X X X
@TimeToTextInZone X X X X X X X X
@TimeZoneToText X X X X X X X X
@Today X X X X X X X X
@Tomorrow X X X X X X X X
@ToNumber X X X X X X X X
@ToTime X X X X X X X X
@Transform X X X X
@Trim X X X X X X X X
@True X X X X X X X X
@Unavailable X X X X X
@UndeleteDocument X X X X
@Unique X X X X X X X X
@UpdateFormulaContext X X X
@UpperCase X X X X X X X X
@URLDecode X X X X X X X X
@URLEncode X X X X X X X X
@URLGetHeader X X X X
@URLHistory X X X
@URLOpen X X X X
@URLQueryString X X
@UserAccess X X X X
@UserName X X X X X X X X
@UserNameLanguage X X X X X X X X
@UserNamesList X X X X
@UserPrivileges X X X X X X X
@UserRoles X X X X X X
@V2If X X X X X X X X
@V3UserName X X X X X X X X
@V4UserAccess X X X X
@ValidateInternetAddress X X X X X X X X
@VerifyPassword X X X X X X X X
@Version X X X X X X X X
@ViewShowThisUnread X X
@ViewTitle X X X X
@WebDBName X X X X X X X X
@Weekday X X X X X X X X
@While X X X X
@Wide X X X X X X X X
@Word X X X X X X X X
@Year X X X X X X X X
@Yes X X X X X X X X
@Yesterday X X X X X X X X
@Zone X X X X X X X X
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 1).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Hotspot
action
& Hotspot
Window formula Form View Layout
title button pop-up Field Form action action Navigator region
@Abs X X X X X X X X X
@Abstract X X X X X X X
@Accessed X X X X X X X X
@ACos X X X X X X X X X
@AddToFolder X X X
@Adjust X X X X X X X X X
@AdminECLIsLocked X X X X X X
@All X X X X X X X X X
@Ascii X X X X X X X X X
@ASin X X X X X X X X X
@ATan X X X X X X X X X
@ATan2 X X X X X X X X X
@AttachmentLengths X X X X X X X X
@AttachmentModifiedTimes X X X X X X
@AttachmentNames X X X X X X X X
@Attachments X X X X X X X X
@Author X X X X X X X X
@Begins X X X X X X X X X
@BrowserInfo X X X X X X X X X
@BusinessDays X X X X X X X X X
@Certificate X
@Char X X X X X X X X X
@CheckAlarms X X X X X
@CheckFormulaSyntax X X X X X X X X X
@ClientType X X X X X X X X
@Command X X X X X X
@Compare X X X X X X X X
@ConfigFile X X X X X X X X X
@Contains X X X X X X X X X
@Cos X X X X X X X X X
@Count X X X X X X X X X
@Created X X X X X X X X
@Date X X X X X X X X X
@Day X X X X X X X X X
@DB2Schema X X X X X X X X X
@DbColumn (Domino) X X X* X X X X X X
@DbColumn (ODBC) X X X X X X X X
@DbCommand(Notes, X
ViewNext/PrevPage)
*@DbCommand (ODBC) X X X X X X X X
@DbExists X X X X X X X X
@DbLookup (Domino) X X X* X X X X X X
@DbLookup (ODBC) X X X X X X X X
@DbManager X X X X X X X X X
@DbName X X X X X X X X X
@DbTitle X X X X X X X X X
@DDEExecute X X X X X X X X
@DDEInitiate X X X X X X
DEFAULT X X X X X X X X X
@DeleteField X X X X X X
@DialogBox X X X X X X X X X
@Do X X X X X X X X X
@DocChildren X
@DocDescendants X
@DocFields X X X X X X X X
@DocLength X X X X X X X X
@DocLevel X
@DocLock X X X X X X
@DocNumber X
@DocOmittedLength X X X X X X X X
@DocParentNumber X
@DocSiblings X
@DocumentUniqueID X X X X X X X X
@Domain X X X X X X X X
@DoWhile X X X X X
*In a Web Application, @DbCommand acts on an embedded view in a document when called from an
action in that document.
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 1).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Note that some @functions return different values when the formula runs on a server.
Hotspot
action
& Hotspot
Window formula Form View Layout
title button pop-up Field Form action action Navigator region
@EditECL X X
@EditUserECL X X
@Elements X X X X X X X X X
@Ends X X X X X X X X X
ENVIRONMENT X X X* X X X X X
@Environment X X X* X X X X X
@Error X X X X X X X X X
@Eval X X X X X X X X X
@Exp X X X X X X X X X
@Explode X X X X X X X X X
@Failure X
@False X X X X X X X X X
FIELD X X X X X X
@FileDir X X X X X X X X X
@FloatEq X X X X X X X X X
@FontList X X X X X X X X X
@For X X X X X
@FormLanguage X X X X X
@GetAddressBooks X X X X X X X X X
@GetCurrentTimeZone X X X X X X X X X
@GetDocField X X X X X X X
@GetField X X X X X X
@GetFocusTable
@GetHTTPHeader X X X X X X X
@GetIMContactListGroupNames X X X X X X X X X
@GetPortsList X X X X X X X X X
@GetProfileField X X X
@GetViewInfo X X
@HashPassword X X X X X X X X X
@Hour X X X X X X X X X
@If X X X X X X X X X
@IfError X X X X X X X X X
@Implode X X X X X X X X X
@InheritedDocumentUniqueID X X X X X X X X
@Integer X X X X X X X X X
@IsAgentEnabled X X X X X X X X X
@IsAppInstalled X X X X X X X X X
@IsAvailable X X X X X X X X
@IsDB2 X X X X X X X X X
@IsDocBeingEdited X X X X X X
@IsDocBeingLoaded X X X
@IsDocBeingMailed X X X X X
@IsDocBeingRecalculated X X X X X
@IsDocBeingSaved X X X X X
@IsDocTruncated X X X X X X X X
@IsEmbeddedInsideWCT X X X X X X X X X
@IsError X X X X X X X X
@IsMember X X X X X X X X X
@IsModalHelp X X X X X X X X X
@IsNewDoc X X X X X X X
@IsNotMember X X X X X X X X X
@IsNull X X X X X X X X
@IsNumber X X X X X X X X X
@IsResponseDoc X X X X X X X X
@IsText X X X X X X X X X
@IsTime X X X X X X X X X
@IsUnavailable X X X X X X X X
@IsValid X X X X X X X X
@IsVirtualizedDirectory X X X X X X X X X
@Keywords X X X X X X X X X
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 1).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Note that some @functions return different values when the formula runs on a server.
Hotspot
action Hotspot
Window & formula Form View Layout
title button pop-up Field Form action action Navigator region
@LanguagePreference X X X X X X X X X
@LaunchApp X X X X X X X X
@LDAPServer X X X X X X X X X
@Left X X X X X X X X X
@LeftBack X X X X X X X X X
@Length X X X X X X X X X
@Like X X X X X X X X X
@Ln X X X X X X X X X
@Locale X X X X X X X X X
@Log X X X X X X X X X
@LowerCase X X X X X X X X X
@MailDbName X X X X X X X X X
@MailEncryptSavedPreference X X X X X X X X X
@MailEncryptSentPreference X X X X X X X X X
@MailSavePreference X X X X X X X X X
@MailSend X X X X X X X
@MailSignPreference X X X X X X X X X
@Matches X X X X X X X X X
@Max X X X X X X X X X
@Member X X X X X X X X X
@Middle X X X X X X X X X
@MiddleBack X X X X X X X X X
@Min X X X X X X X X X
@Minute X X X X X X X X X
@Modified X X X X X X X
@Modulo X X X X X X X X X
@Month X X X X X X X X X
@Name X X X X X X X X X
@NameLookup X X X X X X X X X
@Narrow X X X X X X X X X
@NewLine X X X X X X
@No X X X X X X X X X
@NoteID X X X X X X X
@Nothing X X X X X
@Now X X X X X X X X X
@OptimizeMailAddress X X X X X X X
@OrgDir X X X X X X X X X
@Password X X X X X X X X X
@PasswordQuality X X X X X X X X X
@Pi X X X X X X X X X
@PickList X X X X X X
@Platform X X X X X X X X X
@PolicyIsFieldLocked X X X X X X X X
@PostedCommand X X X X X
@Power X X X X X X X X X
@Prompt X X X X X X X X
@ProperCase X X X X X X X X X
@Random X X X X X X X X X
@RefreshECL X X X
@RegQueryValue X X X X X X X X X
REM X X X X X X X X X
@Repeat X X X X X X X X X
@Replace X X X X X X X X X
@ReplaceSubstring X X X X X X X X X
@ReplicaID X X X X X X X X X
@Responses X
@Return X X X X X X X X X
@Right X X X X X X X X X
@RightBack X X X X X X X X X
@Round X X X X X X X X X
If you need to know whether an @function works in a different context, see Where does this @function
work? (Part 1).
An X indicates that the @function works in that context. A blank cell indicates that the @function does
not work in that context. An asterisk (*) indicates that there is a caveat associated with using an
@function in a particular context.
Note that some @functions return different values when the formula runs on a server.
Hotspot
action Hotspot
Window & formula Form View Layout
title button pop-up Field Form action action Navigator region
@Second X X X X X X X X X
SELECT
@Select X X X X X X X X X
@ServerAccess X X X X X X X X
@ServerName X X X X X X X X
@Set X X X X X X X X X
@SetDocField X X X X X X X
@SetEnvironment X X X X X X X X
@SetField X X X X
@SetHTTPHeader X X X X X X X
@SetProfileField X X X X
@SetTargetFrame X X X
@SetViewInfo X
@Sign X X X X X X X X X
@Sin X X X X X X X X X
@Sort X X X X X X X X
@Sqrt X X X X X X X X X
@StatusBar X X X X X X
@Subset X X X X X X X X X
@Success X
@Sum X X X X X X X X X
@Tan X X X X X X X X X
@TemplateVersion X X X X X X X X X
@Text X X X X X X X X X
@TextToNumber X X X X X X X X X
@TextToTime X X X X X X X X X
@ThisName X
@ThisValue X
@Time X X X X X X X X X
@TimeMerge X X X X X X X X X
@TimeToTextInZone X X X X X X X X
@TimeZoneToText X X X X X X X X X
@Today X X X X X X X X X
@Tomorrow X X X X X X X X X
@ToNumber X X X X X X X X
@ToTime X X X X X X X X
@Transform X X X X X
@Trim X X X X X X X X X
@True X X X X X X X X X
@Unavailable X X X X X X
@Unique X X X X X X X X X
@UndeleteDocument X X X
@UpdateFormulaContext X X X
@UpperCase X X X X X X X X X
@URLDecode X X X X X X X X X
@URLEncode X X X X X X X X X
@URLGetHeader X X X X X X
@URLHistory X X X X X X
@URLOpen X X X X X X
@URLQueryString X X X X X X X
@UserAccess X X X X X X X X
@UserName X X X X X X X X X
@UserNameLanguage X X X X X X X X X
@UserNamesList X X X X X X
@UserPrivileges X X X X X X X X X
@UserRoles X X X X X X X X X
@V2If X X X X X X X X X
@V3UserName X X X X X X X X X
@V4UserAccess X X X X X X X X X
@ValidateInternetAddress X X X X X X X X X
@VerifyPassword X X X X X X X X X
@Version X X X X X X X X X
@ViewShowThisUnread X
@ViewTitle X X X X X X X X X
@WebDBName X X X X X X X X X
@Weekday X X X X X X X X X
@While X X X X X
@Wide X X X X X X X X X
@Word X X X X X X X X X
@Year X X X X X X X X X
@Yes X X X X X X X X X
@Yesterday X X X X X X X X X
@Zone X X X X X X X X X
@DbColumn x
@DbColumn(ODBC) x
@DbCommand x
@DbLookup x
@DbLookup(ODBC) x
@DDEExecute x
@DDEInitiate x
@DDEPoke x
@DDETerminate x
@DeleteDocument x
@DeleteField x
@EditECL x
@EditUserECL x
ENVIRONMENT x
@Environment x
@GetProfileField x
@MailSend x
@RefreshECL x
@SetDocField x
@SetEnvironment x
@SetProfileField x
@Unavailable x
@UpdateFormulaContext x x x
@URLGetHeader x
@URLOpen x
@Abs
Returns the absolute (unsigned) value of a number.
Syntax
@Abs( anyNumber )
Parameters
anyNumber
Number. Any number valid in Lotus Notes/Domino, whether positive or negative, whole or fractional,
integer or real.
Return value
absoluteValue
Usage
When you use this function as the Input translation formula for a Number field, you do not have to
supply the field with a default value.
You can enter a field name as the anyNumber parameter. If you do, be sure that the field you reference in
an @Abs function:
v Is a number field
v Has a default value of zero
Language cross-reference
Abs function in LotusScript language
@Abstract
Abbreviates the contents of one or more fields by:
v Selecting the most significant words in a body of text
v Abbreviating common words
v Dropping vowels from words
v Removing unnecessary text or characters, such as mail headers or white space
Syntax
@Abstract( [ keywords ] ; size ; beginText ; bodyFields )
Parameters
[ keywords ]
Any number of keywords that tell Lotus Notes/Domino how you want to abbreviate and sort the text
(see list below). Keywords are executed in the order in which you list them. Enclose each keyword in
brackets and separate multiple commands with colons: [DROPVOWELS]:[NOTRIMWHITE]:[ABBREV].
size
Number. The maximum size of the abstracted text. Can be no larger than 64,994 bytes. The number of
bytes available for the abstracted text is size - 1; one byte is reserved for internal use.
beginText
Text. A comment to insert at the beginning of the returned text, no larger than 10 characters. The size of
beginText counts toward the total size of the abstracted text, but its contents are unaffected by @Abstract
commands. Specify an empty string () if you do not want a comment.
bodyFields
Text or text list. Any number of fields containing the text to abstract. May be text, rich text, or keyword
fields. The text within each field is concatenated with spaces in the order specified. If Notes/Domino
cannot locate a field by name, it uses the string literal instead. Enclose each field name in quotes and
separate multiple names with colons: Sales:Figures.
Return value
abstractedText
Text. The text contained in each of the body fields, abbreviated and sorted as specified by the commands.
Keywords
You can use the following keywords with @Abstract:
[TEXTONLY]
[COUNTWORDS]
Computes the significance of each word in the text. A words significance depends on the number of
times it appears in the text. A word that appears in the Significant Word file (see Files, below) gets its
significance boosted. A word that appears in the Insignificant Word file (see Files, below) has no
significance.
[SAVE]
Saves the text in its current state. Saved text can be restored with the [RESTORE] keyword.
[RESTORE]
Discards the current text and restores the last-saved text. You can only restore saved text one time. If no
text has been previously saved, this keyword has no effect.
[TRYFIT]
Takes the current text and determines if it has become small enough to fit in the specified size. If so,
@Abstract returns the current text and stops, ignoring any remaining commands. If not, @Abstract
continues with the next keyword.
[SORTCHUNKS]
Sorts the text according to significance. The text is divided into chunks, of which there are three types:
text, mail header, and punctuation.
v Text chunks are usually sentences. They may be at the beginning, end, or middle of a paragraph.
v Mail header chunks are created according to the contents of the Mail Headers file (see Files below).
v Punctuation chunks consist of any text with no letters or digits.
The significance of a chunk depends upon the significances of the words within it, the number of words
in the chunk, and the type and position of the chunk. To use [SORTCHUNKS], you must also use
[COUNTWORDS].
[ABBREV]
[USEDICT]
Specifies that the Abbreviation Dictionary should be used. This is the default.
[NODICT]
[KEEPVOWELS]
[DROPVOWELS]
Removes vowels from words. The first vowel in a word that begins with a vowel isnt affected. If you use
[DROPVOWELS], you can optionally use one of the following subcommands.
[DROPFIRSTVOWEL]
[KEEPFIRSTVOWEL]
[TRIMWHITE]
Removes extra white space characters from the text. This is the default.
[NOTRIMWHITE]
[TRIMPUNCT]
[NOTRIMPUNCT]
[NOSTOPLIST]
[NOSIGLIST]
[TEXTONLY]:[TRYFIT]
Removes all mail header and punctuation chunks. If the text fits, the function is done; otherwise,
continues.
[TRIMPUNCT]:
[SAVE]:
[ABBREV]:[TRYFIT]:
Abbreviates the text. If the text fits, the function is done; otherwise, continues.
[RESTORE]:
[SAVE]:
[DROPVOWELS]:[ABBREV]:[TRYFIT]:
Abbreviates text by dropping vowels. If the text fits, the function is done; otherwise, continues.
[RESTORE]:
[COUNTWORDS]:[SORTCHUNKS]:[ABBREV]
Counts words and sorts the chunks. Abbreviates the text and returns it.
If the removal of mail headers and punctuation allowed the text to fit into the desired size, then text is
returned as is. If the first abbreviation was enough to make the text fit, the returned text begins with a
minus character ( - ). If the second abbreviation was enough to make the text fit, the returned text begins
with a plus character ( + ). If the function counted the words and sorted the chunks, the text will start
with an asterisk ( * ) and the sentences will be separated with a ( | ) to indicate that they were
rearranged.
[TRIMPUNCT]:[ABBREV]
Removes all mail header and punctuation chunks. If the text fits, the function is done; otherwise,
continue.
[TRIMPUNCT]:
[SAVE]:
[ABBREV]:[TRYFIT]:
Abbreviates the text. If the text fits, the function is done; otherwise, continue.
[RESTORE]:
[DROPVOWELS]:
[SAVE]:
[ABBREV]:[TRYFIT]:
[RESTORE]:
[COUNTWORDS]:[SORTCHUNKS]:[ABBREV]
Counts words and sorts the chunks. Abbreviates the text and returns it.
If the function counted the words and sorted the chunks, the returned text begins with an asterisk ( * )
and the sentences are separated with a ( | ) to indicate that they were rearranged.
Files
The following files are used by @Abstract. You can create all, some, or none of these text files, depending
on how you want to use @Abstract. Any files you do create must be named as specified below and be
present in your Notes/Data file path when you start running the software.
Each line of the file should contain two words: the first is the original word and the second is its
abbreviation. An abbreviation must be shorter than the word it replaces. For example:
telephone ph
number no
Specified Resulting
abbreviation Word being replaced abbreviation Reasoning
Phone telephone Phone The original word appears in lowercase, so the
specified abbreviations case is used.
Phone TElephone PHONE The abbreviations case is based upon the original
words case.
Phone Telephone Phone The abbreviations case is based upon the original
words case.
PHONE Telephone PHONE The abbreviation is specified as uppercase, so it
always appears as uppercase.
Phone tElephone PHONE The first letter of the abbreviation was already
uppercase, so Notes/Domino leaves it alone. The
remaining letters of the abbreviation are
converted to uppercase to match the second letter
of the original word.
The file should be a free-form list of significant words, such as urgent or immediately. When
@Abstract computes the significance of text, it boosts the significance of any words included in the
significant word list. For example:
client
boss
chocolate
The file should be a free-form list of words that are always insignificant, such as the, and, and of.
When @Abstract computes the significance of words, it ignores any words included in this file. For
example:
the
and
of
The file should be a free-form list of words that indicate mail headers, such as Subject, From, and To. In
order for @Abstract to consider a chunk a mail header, it must begin with one of the words specified in
Language cross-reference
Abstract method in LotusScript NotesItem class
Examples: @Abstract
1. This formula abbreviates the contents of the description field by eliminating vowels.
@Abstract( [DROPVOWELS]:[ABBREV]; 200; ""; "description" )
If the description field contained this text: The kickoff meeting for our capital campaign is tomorrow.
Then the formula returns: Th kckff mtng fr or cptl cmpgn is tmrrw.
2. This formula abbreviates the contents of the description field by using an Abbreviation Dictionary and
eliminating vowels, including the vowels that appear as the first letter in a word.
@Abstract([USEDICT]:[DROPVOWELS]:[DROPFIRSTVOWEL]:[ABBREV]; 200; ""; "description" )
If the Abbreviation Dictionary contains the following:
capital cap meeting mtg tomorrow tom
Then the formula returns:Th kckff mtg fr r cap cmpgn s tom.
3. This formula shows a misunderstanding in the use of @Abstract. It returns the contents of the
description field unaltered, since the [ABBREV] keyword incorrectly precedes [DROPVOWELS].
@Abstract( [ABBREV]:[DROPVOWELS]; 200; ""; "description" )
4. This formula removes the white spaces from around all punctuation and abbreviates the text in the
opinion field according to the noteabbr.txt file, which containts the following:
following flwg punctuation punc
@Abstract([RULE2];300;"Result:";"opinion")
If the opinion field contains the text: The FOllowing is a list of punctuation marks: ! , ; :.
Then the formula returns: Result:The FLWG is a list of punc marks:!<;:.
@Accessed
Indicates the time and date when the document was last accessed by a Lotus Notes client, whether for
reading or editing.
Syntax
@Accessed
Return value
lastAccessed
Time-date. The time and date that the current document was last accessed.
The value returned by @Accessed is exact only to the day, not the hour. If the document is edited, the
property is always updated. If the document is read more than once during the same 24hour period, the
value is only updated the first time accessed.
The lastaccessed value is not replicated; each replica copy of the document maintains its own value. The
value returned by @Accessed represents the last time the document was accessed in that replica of the
database.
If the database is stored on CD-ROM, @Accessed has no meaning because read/write access is not
controlled by the Notes/Domino editor.
@Accessed can also be used in an agent to determine which documents in a database have not been
accessed within a certain period of time, and archive them.
Note: @Accessed is similar to @Modified, which records the date the document was last edited and
saved.
Language cross-reference
LastAccessed property in LotusScript NotesDocument class
Examples: @Accessed
This formula returns: 06/22/95 10:46:03 AM; if the document was last read or edited on June 22, 1995 at
10:46:03 AM.
@Accessed
@ACos
Calculates the arc (inverse) cosine, using the cosine of an angle.
Syntax
@ACos( cosine )
Return value
angle
Number. An angle, in radians, from 0 through pi. This represents an angle between 0 and 180 degrees.
Language cross-reference
ACos function in LotusScript language
Examples: @ACos
1. This example returns pi/2.
@ACos( 0 )
2. This example returns 1.0472 radians (60 degrees).
@ACos( 0.5 )
@AddToFolder
Adds current document to one folder while removing it from another. NULL string can be substituted for
either argument to skip the action.
Syntax
@AddToFolder(foldernameadd ; foldernameremove)
Parameters
foldernameadd
foldernameremove
Usage
This formula can be used in toolbar button and agent formulas.
Language cross-reference
Folder method in LotusScript NotesUIWorkspace class
Examples: @AddToFolder
1. This example adds the currently selected document to the folder named Work.
@AddToFolder("Work";"")
2. This example adds the currently selected document to the folder named Work and removes it from
the folder named Favorites.
@AddToFolder("Work";"Favorites")
@Adjust
Adjusts the specified timedate value by the number of years, months, days, hours, minutes, and/or
seconds you specify. The amount of adjustment may be positive or negative.
Syntax
@Adjust( dateToAdjust ; years ; months ; days ; hours ; minutes ; seconds ; [DST] )
Parameters
dateToAdjust
Time-date. The time-date value you want to increment. This should be a single value, not a range.
years
months
days
hours
minutes
seconds
[DST]
Keyword. Optional. Specify [INLOCALTIME] to further adjust the time for daylight-saving time if the
adjustment crosses the boundary and daylight-saving time is in effect. Specify [INGMT] or omit this
parameter to not further adjust the time for daylight-saving time. The adjustment is such that adding or
subtracting in day increments yields the same time in the new day.
Time-date. The date, incremented by the amount of time you have specified.
Usage
You must include all arguments except the [DST] keyword; include a zero (0) for parameters you dont
want to adjust.
Tip: To find the difference between two dates, subtract them. The result is returned in seconds. To adjust
the result to days, divide the result by 86,400 - which is the number of seconds in a day. For example, if
you have two date fields, date1, which contains [07/01/01] and date2, which contains [07/05/01], use the
following formula to return the number of days between the two dates:
(date2-date1)/86400
Language cross-reference
AdjustYear method in LotusScript NotesDateTime class
Examples: @Adjust
1. This example returns 09/2/97.
@Adjust([06/30/95];2;2;2;0;0;0)
Lotus Notes/Domino sees 30 in the days portion of the timedate value and adjusts it by 2, which
increments the month value by 1. Lotus Notes/Domino then adjusts the month value by 2, and the
year value by 2.
2. This example returns 03/20/94.
Chapter 6. Formula Language @Functions A-Z 207
@Adjust([03/30/96];2;0;10;0;0;0)
Notes/Domino returns a date that is 2 years and 10 days before the supplied date.
3. This example returns the date one month from the date in the field named Date.
@Adjust(Date;0;1;0;0;0;0)
4. This example returns the date one month and one day from the current timedate.
@Adjust(@Now;0;1;1;0;0;0)
5. Given a date, this formula calculates the beginning of the week. It takes the date stored in the
dueDate field, and returns the date representing the previous Monday. For example, if dueDate is
06/02/95, this formula returns 05/29/95.
@Adjust( dueDate; 0; 0; - ( @Weekday( dueDate ) - 2 ); 0; 0; 0 )
@AdminECLIsLocked
Note: This @function is new with Release 7.
Checks the current status of the Administration ECL in the name and address book and returns 1 (True)
if the Administration ECL is locked and editing is prevented; otherwise returns 0 (False).
Syntax
@AdminECLIsLocked
Return value
flag
Boolean
v 1 (True) indicates that the Administration ECL is locked and may not be edited
v 0 (False) indicates that the Administration ECL is not locked
Usage
You cannot use this function in Web applications. In Release 7, this function will be used in pubnames.ntf
to determine if AdminECL is locked or not.
@All
Returns the value True.
Syntax
@All
Return value
flag
Usage
Use @All in selection formulas, mail agents, paste agents, scheduled agents, or in any formula requiring a
SELECT statement. Lotus Notes/Domino appends SELECT @All to agents in contexts where @All is
needed. All views default to a selection formula of SELECT @All.
@AllChildren
Includes all response documents at all levels for parent documents that match selection criteria.
Syntax
SELECT selectionFormula I @AllChildren
Return value
Selects all the documents that match selectionFormula plus their immediate responses.
Usage
@AllChildren can only be used in a view selection or selective replication formula. It must be appended
to the end of a selection formula using the Boolean OR operator (|). Dont use it within complex
expressions in a formula.
@AllChildren allows you to define a view as a set of documents that match a given formula plus the
immediate responses to those documents. It also allows you to create a selective replication formula to
replicate a set of documents along with the immediate responses.
Selection formulas that use @AllChildren may provide a significant advantage over formulas that use
@IsResponseDoc. While @IsResponseDoc returns True for anyresponse document in a database,
@AllChildren returns only those responses that are immediate children of matching documents.
@AllDescendants
Includes all response and response-to-response documents for parents that match selection criteria.
Syntax
SELECT selectionFormula I @AllDescendants
Return value
Selects all the documents that match selectionFormula plus their responses and responses-to-responses, for
as many levels of response documents as exist.
Usage
@AllDescendants can only be used in a view selection or selective replication formula. It must be
appended to the end of a selection formula using the Boolean OR operator (|). Dont use it within
complex expressions in a formula.
@AllDescendants allows you to define a view as a set of documents that match a given formula plus all
the responses to those documents, at any level. It also allows you to create a selective replication formula
to replicate a set of documents along with all responses.
@Ascii
Converts an LMBCS (Lotus Multi-Byte Character Set) string to an ASCII string.
Syntax
@Ascii( string ) @Ascii( string ; [ALLINRANGE] )
Parameters
string
[ALLINRANGE]
Keyword. Optional. Specifies that @Ascii should return a null string () if any characters in the original
string cannot be represented by ASCII codes 32 to 127.
Return value
newString
Text or text-list. The original string, with each character converted to an ASCII-compliant character. Any
character that cant be represented by ASCII codes 32 to 127 is replaced with a question mark (?). If you
specify [ALLINRANGE] and there are characters that cant be represented by ASCII codes 32 to 127,
returns a null string ().
Usage
@Ascii first converts the string into ASCII-compliant characters, replacing any unrepresented characters
with question marks, and then, if [ALLINRANGE] is True, checks for question marks within the string.
This means that if the original string contains a question mark and [ALLINRANGE] is specified, a null
string is returned even if the entire string can be represented by ASCII codes 32-127.
@ASin
Calculates the arc (inverse) sine using the sine of an angle.
Syntax
@ASin( sine )
Parameters
sine
Return value
angle
Number. An angle, in radians, from -pi/2 through pi/2. This represents an angle between -90 and 90
degrees.
Language cross-reference
ASin function in LotusScript language
Examples: @ASin
1. This example returns pi/2.
@ASin( 1 )
2. This example returns 0.72082 radians (41.3 degrees).
@ASin ( 0.66 )
@ATan
Calculates the arc (inverse) tangent using the tangent of an angle.
Syntax
@ATan( tangent )
Parameters
tangent
Number. An angle, in radians, from -pi/2 through pi/2. This represents an angle between -90 and 90
degrees.
Language cross-reference
ATn function in LotusScript language
Examples: @ATan
1. This example returns pi/4.
@ATan( 1 )
2. This example returns -pi/4.
@ATan( -1 )
3. This example returns 1.10715 radians (63.4 degrees).
@ATan( 2 )
@ATan2
Calculates the arc tangent using the tangent y/x of an angle.
Syntax
@ATan2( x ; y )
Parameters
x
Return value
angle
Number. An angle, in radians, from -pi through pi. This represents an angle between -180 and 180
degrees, depending on the sign of x and y (see the list below).
y is positive
x is negative pi/2 to pi (Quadrant II)
y is positive
x is negative -pi to -pi/2 (Quadrant III)
y is negative
x is positive -pi/2 to 0 (Quadrant IV)
y is negative
Examples: @ATan2
1. This example returns pi/4.
@ATan2( 1; 1 )
2. This example returns 3pi/4.
@ATan2( -1; 1 )
3. This example returns 1.10715 radians (63.4 degrees).
@ATan2 ( 1; 2 )
@AttachmentLengths
Returns a number or a number list containing the length of each attachment to the current document. The
number(s) returned are only approximations; the actual size(s) of the attachment(s) may be slightly
different.
Syntax
@AttachmentLengths( excludeMIMEBody )
Parameters
excludeMIMEBody
Boolean. Optional.
v Specify True (1) to exclude large MIME parts that are stored as attachments (but displayed in-line).
This is the default.
v Specify False (0) to include large MIME parts that are stored as attachments (but displayed in-line).
Return value
sizeInBytes
Usage
The attachment size is computed based on uncompressed file size (that is, the number of bytes the
attachment would use if you extracted it); the actual disk storage space required for the file may be
somewhat smaller.
@AttachmentLengths returns an empty list if there are no attachments. If there is one attachment of
length 0, @AttachmentLengths returns 0.
Examples: @AttachmentLengths
1. This example returns 6102 if that is the approximate size of the single, attached file.
@AttachmentLengths
2. This example, given a semicolon as the multivalue separator, returns
AUTOEXEC.BAt:112;CONFIG.SYS:1549;Q4SALES.WK4:17636 if those are the names and lengths of the
files attached.
@AttachmentNames + ":" + @Text(@AttachmentLengths)
3. This example returns 0 if there is one attachment of length 0.
@AttachmentLengths
4. This example returns an empty list (no value appears at all) if there are no attachments.
@AttachmentLengths
5. This example sums the attachment lengths, checking first to make sure there are attachments.
@Sum(@Attachments > 0; @AttachmentLengths; 0)
@AttachmentModifiedTimes
Returns a datetime that displays the date on which the file attachment associated with the current
document was last modified. If the document contains more than one file attachment, returns the
modification dates in a datetime list.
Syntax
@AttachmentModifiedTimes( excludeMIMEBody )
Parameters
excludeMIMEBody
Boolean. Optional.
v Specify True (1) to exclude large MIME parts that are stored as attachments (but displayed in-line).
This is the default.
v Specify False (0) to include large MIME parts that are stored as attachments (but displayed in-line).
Return value
modificationDate
@AttachmentNames
Returns the operating system file names of any files attached to a document. If there are multiple files
attached, the names are returned as a multiplevalue text list.
Syntax
@AttachmentNames( excludeMIMEBody )
Parameters
excludeMIMEBody
Boolean. Optional.
v Specify True (1) to exclude large MIME parts that are stored as attachments (but displayed in-line).
This is the default.
v Specify False (0) to include large MIME parts that are stored as attachments (but displayed in-line).
Return value
names
Language cross-reference
Source property in LotusScript NotesEmbeddedObject class
@Attachments
Returns the number of files attached to a document.
Syntax
@Attachments( excludeMIMEBody )
Parameters
excludeMIMEBody
Boolean. Optional.
v Specify True (1) to exclude large MIME parts that are stored as attachments (but displayed in-line).
This is the default.
v Specify False (0) to include large MIME parts that are stored as attachments (but displayed in-line).
Return value
numFiles
Examples: @Attachments
1. This example returns 3 if there are three files attached to a document.
@Attachments
2. This example returns 0 if there are no files attached to a document.
@Attachments
@Author
Returns a text list containing the names of the author(s) of the current document.
Syntax
@Author
Return value
authorList
@Author uses the following instructions (in the sequence outlined below) to find document author(s) and
return the appropriate text list:
1. Search the document for a field of type Authors. If there is one, return the name(s) stored there. (If
there are multiple Authors fields, returns the contents of the first Authors field found in the
document.)
2. If there is no Authors field, look for a field called From. If there is a From field, look for the field
FromDomain.
v If both fields are found, combine the two fields, separating them by an @ sign (as in, Mary
Tsen@AcmeWest).
v Otherwise, return the contents of the From field only.
3. If there is no From field, look for a field named $UpdatedBy. If there is one, return the contents of the
field.
4. If there is no $UpdatedBy field and this is a new document (not yet saved), return the current users
name.
5. If none of the above can be found, return the null string ().
Usage
@Author is most useful for documents containing an Author Names or From field.
Language cross-reference
FieldGetText method in LotusScript NotesUIDocument class
Examples: @Author
If a document has one Authors field that contains: Mary Tsen, David Smith, Denise Lee/Research/Acme.
This example returns: Mary Tsen; David Smith; Denise Lee/Research/Acme.
@Author
@Begins
Determines whether a particular substring is stored at the beginning of another string.
Syntax
@Begins( string ; substring )
Parameters
string
Text. The string you want to search for at the beginning of string.
Return value
flag
Boolean.
v Returns 1 (True) if substring is contained within string, beginning from the first letter
v Returns 0 (False) if not
Usage
This function is case-sensitive.
Examples: @Begins
1. This example returns 1.
@Begins("Hi There";"Hi")
2. This example returns 0.
@Begins("Hi There";"hi")
3. This example checks the field named Topic; if that field begins with the string All desks memo,
returns the string: Junk Mail. Otherwise, it returns the string: Read this first.
@If(@Begins(Topic;"All desks memo");"Junk Mail"; "Read this first")
@BrowserInfo
Determines the capabilities of a Web client, that is you can determine the properties of the browser for
the current request.
Syntax
@BrowserInfo( propertyname )
Parameters
propertyname
Return value
The return value type is dependent on the capability. The table below shows the current set of Web
browser and Notes client capabilities that Lotus Notes/Domino supports:
Property name Return type Return value for browsers Return value for Notes client
BrowserType Text The type of the browser: Microsoft, Notes
Netscape, Compatible (for
browsers that claim to be compatible
with Netscape, including Notes
Navigator 5.0), or Unknown.
Cookies Boolean 1 (True) if the browser supports 0 (False)
cookies; otherwise 0 (False).
Usage
@BrowserInfo determines the properties of a browser by matching the HTTP User-Agent header sent by
the browser to property rules in the browser.cnf file in the Lotus Domino data directory. @BrowserInfo
also contains hard-coded rules for the Notes client.
@BrowserInfo can be used in all types of formulas except view selection and view column formulas.
Pre-5.0 Notes clients will not be able to open forms that use @BrowserInfo. The client will display the
error message Invalid formula: unknown function/operator. To prevent this error, check the version
number of the client in your formulas. Example:
Language cross-reference
CGI variables
Examples: @BrowserInfo
This example displays the value in the field named KeyThought, if the current browser supports
JavaScript; otherwise the value in the field Topic is displayed.
@BusinessDays
Returns the number of business days in one or more date ranges.
Syntax
@BusinessDays( startDates ; endDates ; daysToExclude ; datesToExclude )
Parameters
startDates
endDates
daysToExclude
Numer or number list. Optional. Days of the week not counted as business days, where 1 is Sunday and
7 is Saturday. Decimal numbers are rounded to integers. Numbers other than 1-7 are ignored.
datesToExclude
Return value
numberOfDays
Number or number list. The number of days from startDates to endDates, inclusive, less daysToExclude and
datesToExclude that fall within the date range.
Usage
The operation on startDates and endDates is a pair-wise list operation. If they are not the same length, the
shorter list is filled out with the value of the last element.
@BusinessDays returns -1 if the calculation produces a negative number of days, an end date precedes a
start date, or a time-date value contains only a time.
Examples: @BusinessDays
1. This agent displays the number of days in 2001 excluding Saturdays, Sundays, and 10 holidays.
@Prompt([OK];
@Text(
@BusinessDays([01/01/2001]; [12/31/2001]; 1 : 7;
[01/01/2001] : [01/15/2001] : [02/16/2001] : [05/28/2001] : [07/04/2001] :
[09/03/2001] : [10/08/2001] : [11/22/2001] : [11/23/2001] : [12/25/2001])
);
"Business days in 2001")
2. This agent displays the number of days in each quarter of 2001 excluding Saturdays, Sundays, and 10
holidays.
@Certificate
Extracts information from the Certified Public Key in the Domino Directory.
Syntax
@Certificate( [ dataToRetrieve ] ; Certificate )
Parameters
[ dataToRetrieve ]
Keyword. Must be enclosed in brackets as shown. Use one of the following keywords:
[SUBJECT]
[ISSUER]
[EXPIRATION]
The date and time that the North American certificate expires.
[INTLEXPIRATION]
Certificate
Return value
dataRetrieved
Text for the Subject and Issuer names, and time-date values for the Expiration and IntlExpiration dates.
Usage
@Certificate is useful within a macro or view selection formula for selecting a list of users whose
certificates are about to expire; it is used by several Domino Directory tools.
@Certificate only retrieves data; you cannot use it to change certificate information (use the appropriate
Administration menus to update certificates). Certified Public Key information is stored only for users
and servers with hierarchical IDs; @Certificate returns a null string for nonhierarchical IDs.
If you use incorrect syntax, @Certificate returns a null string and does not generate an error message.
@Certificate returns a null string (), instead of the name of the server ID, when used in a Scheduled
agent running on the server.
Language cross-reference
Signer property of LotusScript NotesDocument class
Examples: @Certificate
1. This example returns CN=Michael Bowling/OU=R&D/O=WorkSavers/C=US for Michael Bowlings
hierarchical ID.
@Certificate([SUBJECT];Certificate)
2. This example returns the name of the ID that certified the ID.
@Certificate([ISSUER];Certificate)
3. This example returns the date and time the North American ID expires.
@Certificate([EXPIRATION];Certificate)
4. This example returns the date and time the International ID expires.
@Certificate([INTLEXPIRATION];Certificate)
@Char
Converts an IBM Code Page 850 code number into the corresponding single character string.
Syntax
@Char( codeNumber )
Parameters
codeNumber
Number. Any number between 0 and 255. Noninteger numbers are truncated to integers.
Usage
@Char(10) returns a carriage return.
Note: In the Notes client, the codeNumber parameters 0 and 9 do not work in column formulas.
Language cross-reference
Tab function of LotusScript language
Examples: @Char
1. This example returns: A.
@Char(65)
2. This example returns: a.
@Char(97)
3. This example returns: 8.
@Char(56)
4. This example returns the character in the field named QuestionnaireNumber if that field is currently
filled in; otherwise, returns a null string.
@If(@IsAvailable(QuestionnaireNumber);
@Char(QuestionnaireNumber);"")
5. This example uses @Char(13) to insert a carriage return into the text of @Prompt.
@Prompt([OK]; "Complete"; "The agent has finished." + @Char(13) + "Please exit this document without saving.")
Syntax
@CheckAlarms
Usage
You use @CheckAlarms whenever you make changes to any scheduling that involves alarms. This
includes creating a new appointment or anniversary event with an alarm, changing an existing
appointment that has an alarm (because the mailer daemon has to reread the information to find out
when the new alarm should go off), or deleting an appointment that had an alarm.
Language cross-reference
CheckAlarms method of LotusScript NotesUIWorkspace class
@CheckFormulaSyntax
Checks a block of commented out formula language code for errors.
Syntax
@CheckFormulaSyntax(formulaText)
Parameters
formulaText
Text. The formula code to test for errors, commented out. Enclose the formula code in braces ({}) to
comment out the code.
Return value
errorInformation
Text or textlist.
v Returns 1 if the formula has no errors.
v Returns the text list errorMessage : errorLine : errorColumn : errorOffset : errorLength : errorText
where each list item is defined as follows:
errorMessage: Message returned by the compiler.
errorLine: Line where the error occurred, beginning with 1, not zero. New lines created by wrapped text
are not counted.
errorColumn: Number of character spaces from the first character in the line where the error occurred,
beginning with 1.
errorOffset: Number of character spaces from the first character in the formulaText block where the
error occurred, beginning with 1.
errorLength: Length of the text making up the error.
errorText: Text or token that the compiler processes as the cause of the error.
Examples: @CheckFormulaSyntax
1. This example returns Unknown @Function:4:1:60:8:@MailSnd when used as the default
value for a text field.
formula := {subject:="test";
remark:="ok";
SendTo:="Darrin Dogs/Star";
@MailSnd(SendTo;"";"";subject;remark;"ID";[Sign]:[Encrypt])};
@CheckFormulaSyntax(formula);
2. This code returns 1 when used as the default value for a text field.
formula := {subject:="test";
remark:="ok";
SendTo:="Darrin Dogs/Star";
@MailSend(SendTo;"";"";subject;remark;"ID";[Sign]:[Encrypt])};
@CheckFormulaSyntax(formula);
@ClientType
Returns a text string to differentiate Lotus Notes clients and World Wide Web browsers.
Syntax
@ClientType
Return value
client type
Text.
v Returns Notes if the client type is a Lotus Notes client
v Returns Web if the client type is a Web browser
Usage
@ClientType is useful within database formulas, form formulas, buttons in forms, and hide-when
formulas. Do not use @ClientType in column formulas.
Examples: @ClientType
1. This example returns the client type.
@Prompt([OK]; "Client type"; @ClientType)
2. This example, used in a button, opens a view called By Category - Notes if the client type is
Notes, or a view called By Category - Web otherwise.
@If(@ClientType = "Notes"; @Command([OpenView];
"By Category - Notes");
@Command([OpenView]; "By Category - Web"))
Syntax
@Command( [ command ] ; parameters )
Usage
This function does not work in column, selection, hide-when, section editor, window title, field, or form
formulas, or in agents that run on a server. Its intended for use in toolbar button, hotspot, and action
formulas.
Exceptions
The commands listed in the Evaluated after all @functions column in the table below always execute after
all the functions present in a formula are executed, which means that the action performed by a
command cannot be used by a function that follows it in a formula. The commands listed in the
Evaluated immediately column have the equivalent functionality to the corresponding Evaluated after all
@functions commands, except they execute as soon as they are encountered in the formula.
Syntax
@Compare( textlist ; textlist ; [ options ] )
Parameters
textlist
Text list. The first two parameters are text lists. If one list is shorter, the last element in the shorter list is
repeated until it reaches the same length as the longer list. The corresponding elements of each list are
compared.
[ options ]
Keyword list. The list can include any of the following keywords. Conflicting options result in the last
specified.
[CASESENSITIVE] (default)
[CASEINSENSITIVE]
[ACCENTSENSITIVE] (default)
[ACCENTINSENSITIVE]
[PITCHSENSITIVE] (default)
[PITCHINSENSITIVE]
Return value
result
Number list. Each element is the result of comparing the corresponding elements in the text lists, and is
one of three values:
v 0 if the elements in the two lists are equal
v -1 if the element in the first list is less than the element in the second list. For example, this is the result
if the first list contains alice and the second list contains bobby.
v 1 if the element in the first list is greater than the element in the second list. For example, this is the
result if the first list contains bobby and the second list contains alice.
Usage
The comparison sequence for the English character set is as follows: the apostrophe, the dash, the
numbers 0-9, the alphabetic characters a-z and A-Z, and the remaining special characters. The sequence
for the alphabetic characters is in order, lowercase character first: a, A, b, B, and so on through z, Z. This
sequence can lead to some anomalies; for example, new york compares before New Boston. Use the
[CaseInsensitive] option, or @UpperCase, @LowerCase, and @ProperCase to address this behavior.
If you set Unicode standard sorting as the sorting option, you cannot select the following keywords or
combinations:
You specify Unicode standard sorting by setting the notes.ini variable $CollationType to @UCA, or by
selecting the Unicode standard sorting checkbox that displays in the following dialog boxes:
v Sorting dialog box that displays when you choose File - Preferences - User Preferences - International -
Sorting from the main menu
v Database Properties box*
v Design Document Properties box*
*The Unicode option is disabled in the Database and Design Document Properties boxes until you select
a default sort order.
Language cross-reference
StrCompare function of LotusScript language
Examples: @Compare
1. This action compares a list to the value N and displays the result. Boston and Moscow result in -1
(less than N), Tokyo results in 1 (greater than N), and n and N result in 0.
list := "Boston" : "Tokyo" : "Moscow" : "N" : "n";
result := @text(@compare(list; "N"; [CaseInsensitive]));
@Prompt([OKCANCELLIST] : [NOSORT];
"Result"; ""; ""; list + " (" + result + ")")
2. This computed field formula compares the two multi-value fields Name1 and Name2 and posts the
result as its value. Text is substituted for the numeric result values.
@If(Names1 = "" | Names2 = ""; ""; @do(
comp1 := @Compare(Names1; Names2;
[CASEINSENSITIVE] : [ACCENTINSENSITIVE]);
comp2 := @Replace(@Text(comp1); "-1" : "0" : "1";
" is less than " : " is equal to " : " is greater than ");
Names1 + comp2 + Names2))
3. This computed field formula for a multi-value field named Column2 compares Column1 with A and
Z to see if its values start in the alphabetic range. Text is posted to Column2 when the value in
Column1 is out of range.
@If(Column1 = ""; ""; @Do(
Low1 := @Compare(Column1; "A"; [CASEINSENSITIVE]);
High1 := @Compare(Column1; "Z"; [CASEINSENSITIVE]);
Low2 := @Replace(@Text(Low1); "-1" : "0" : "1"; "Does not start with alpha" : "" : "");
High2 := @Replace(@Text(High1); "-1" : "0" : "1"; "" : "" : "Does not start with alpha");
Low2 + High2))
4. This formula retrieves all the elements that begin with a, b, or c from the text list in the sailboats field:
@For(n:=1;n <= @Elements(sailboats);n := n+1;
FIELD result := @If(n=1;@If(@Compare(sailboats[n];"d";[CASEINSENSITIVE])=-1;
sailboats[n];"");@If(@Compare(sailboats[n];"d";[CASEINSENSITIVE])=-1;
result:(sailboats[n]);result)));
result
If the sailboats field contains Hunter:C&C:Pearson:Contessa:Bristol, this formula returns
C&C;Contessa;Bristol.
Syntax
@ConfigFile
Return value
notes.ini path
Usage
When the formula is executed on the Notes client, it returns the filename and path of the notes.ini
initialization file for the Notes client. When the formula is executed on the server or Web server (when
accessed in a Web page, for example), it returns the filename and path of the notes.ini initialization file
for the server.
Examples: @ConfigFile
1. This formula, when added to a computed field on a form and previewed in Notes, returns:
C:\Lotus\Notes\notes.ini if the current Notes client was installed with the standard file
configuration.
@ConfigFile
2. This formula, when added as computed text to a page, returns D:\webapp\notes.ini, when the page
being previewed by a Web browser resides in a database hosted by the webapp server.
@ConfigFile
@Contains
Determines whether a substring is stored within a string.
Syntax
@Contains( string ; substring )
Parameters
string
substring
Text or text list. The string(s) you want to search for in string.
Return value
flag
Boolean.
v Returns true (1) if any substring is contained in one of the strings
v Returns false (0) if no substrings are contained in any of the strings
Usage
This function is case-sensitive.
You cannot use this function to test for substrings in a rich text field.
Language cross-reference
InStr function in the LotusScript language
Examples: @Contains
1. This example returns 1 to indicate that the substring, Th, is contained in the string, Hi There.
@Contains("Hi There";"Th")
2. This example returns 1 to indicate that the items in one text list are contained in the other text list.
@Contains("Tom":"Dick":"Harry";"Harry":"Tom")
3. This example returns 1 to indicate that the single text item in one parameter is present in the text list
that makes up the other parameter.
@Contains("Tom";"Tom":"Dick":"Harry")
4. This input validation formula for the RequestShipDate field checks if the date in the field is invalid
or if the field named ProductLeadTime contains the phrases weeks or month. If either condition is
true, when the user saves the document a message box displays stating, You must request a valid
ship date.
@If(@Contains(ProductLeadTime;"weeks":"month"); @If(!@IsTime(RequestedShipDate);
@Failure("You must request a valid ship date.");@Success;@Success)
5. This view selection formula creates a new view that includes only documents that have a Subject field
containing the text Mary Lamb (in any case).
SELECT form = "Memo" & @Contains(@LowerCase(Subject); "mary lamb")
6. This action formula opens a WebForm instead of a NotesForm if the user executing the action is
assigned the role of [WebUser] in the ACL.
@Command([Compose]; @If(@Contains(@UserRoles; "WebUser"); "WebForm"; "NotesForm"))
Note: For this example to work, the Enforce a consistent ACL across all replicas of this database
option must be selected.
@Cos
Given an angle in radians, returns the cosine of the angle. In a right triangle, the cosine of an acute angle
is the ratio of the length of its adjacent side to the length of the hypotenuse.
Syntax
@Cos( angle )
Parameters
angle
Return value
cosine
Examples: @Cos
1. This formula returns 1.
@Cos( 2 * @Pi )
2. This formula finds the length of side c in triangle ABC. You know the value of angle C in radians,
and the lengths of sides a and b. This formula finds the length of side c.
@Sqrt( @Power( sideA; 2 )+@Power( sideB; 2 )-
( 2*sideA*sideB*( @Cos( angleC ) ) ))
This formula is a version of the law of cosines, which states that for any triangle ABC, c2 =
a2+b2-2ab(cos(C)).
@Count
Calculates the number of text, number, or timedate values in a list. This function always returns a
number to indicate the number of entries in the list.
This function is similar to @Elements, except that it returns the number 1 instead of 0, when the value it
is evaluating is not a list or is a null string.
Syntax
@Count( list )
Parameters
list
Return value
numElements
Number. The number of elements in the list. If the value is not a list or is a null string, @Count(list)
returns the number 1.
Language cross-reference
GetItemValue method of LotusScript NotesDocument class
Examples: @Count
1. This formula returns the value 3 when the stooges field contains the text list: Moe:Larry:Curly:
@Count(stooges)
2. This code returns the value 1, even if there are 4 entries under the Kevlar category in the Sails view,
when the value of the third column in the view is determined by the simple function, # in View:
@Created
Returns the timedate when the document was created.
Syntax
@Created
Return value
dateCreated
Usage
@Created differs from @Now, in that @Created returns a timedate value that remains constant, while
@Now returns a dynamic timedate that changes with each formula evaluation when it is used in a
computed field.
In a field formula, Lotus Notes/Domino takes the value for @Created from the server clock, unless the
database is local.
Language cross-reference
Created property of LotusScript NotesDocument class
Examples: @Created
1. This example returns 06/23/95 11:36:50 AM for a document created on June 23, 1995, at 11:36:50 A.M.
@Created
2. This example returns 8/4/93 3:10:00 PM for a document created on April 4, 1992 at 3:10 P.M.
@Adjust(@Created;1;4;0;0;0;0)
See @Adjust for an explanation of the parameters following @Created above.
3. This code, when added as the view selection formula, populates the view with only those documents
created after July 23, 2001.
SELECT @Created > [07/23/2001]
@Date
Translates numbers for the various components of time and date, then returns the timedate value.
Syntax
@Date( year ; month ; day ) @Date( year ; month ; day ; hour ; minute ; second ) @Date( time-date )
Parameters
year
Number. The year that you want to appear in the resulting date. You must specify an entire four-digit
year. (For example, use 1996, not 96).
month
Number. The month that you want to appear in the resulting date.
day
Number. The day that you want to appear in the resulting date.
hour
Number. The number of hours. This value will be truncated from the resulting date.
minute
Number. The number of minutes. This value will be truncated from the resulting date.
second
Number. The number of seconds. This value will be truncated from the resulting date.
time-date
Time-date. For a timedate value such as @Now or [10/31/93 12:00:00], @Date removes the time portion
of the value, leaving only the date.
Return value
truncatedTimeDate
Time-date. The date corresponding to the parameters that you sent to @Date, minus any time
components.
Examples: @Date
1. This example returns 06/23/95.
@Date(1995; 06; 23)
2. This example returns 06/23/0095.
@Date(95; 06; 23)
3. This example returns 06/23/2095.
@Date(2095; 06; 23)
4. This example returns 06/23/95 if the timedate value in the field named ResponseDate is 06/23/95
03:00:01 P.M.
@Date(ResponseDate)
5. This example returns 1/20/93 08:58:12 AM.
@Date(1993; 01; 20; 8; 58; 12)
6. This example returns 11/20/95.
@Date([11/20/95 8:58:12])
@Day
Extracts the day of the month from the specified date.
Syntax
@Day( timeDateValue )
Parameters
timeDateValue
Time-date. The date containing the day value that you want to extract.
Return value
dayOfMonth
Number. The number corresponding to the day of the month indicated by timeDateValue. Returns -1 if the
time-date provided contains only a time value and not a date.
Language cross-reference
Day function of LotusScript language
Examples: @Day
1. This example returns 15 if today is July 15, August 15, September 15, and so on.
@Day(@Now)
@DB2Schema
Given the name of a database as a text string, returns a text string containing the DB2 schema of that
database if it is a db2nsf database or the empty string if it is not a db2nsf database.
Syntax
@DB2Schema( server : file )
Parameters
server
file
Text. The path and file name of the database. Specify the database path and file name using the
appropriate format for the operating system.
replicaID
Return value
schema
Text. The DB2 schema of the nsf database indicated by server : fileor server ; replicaID. The empty string
() is returned if the database is a non-DB2 database. Returns an error via @Error if:
v The server cannot be reached
v The database specified in file or replicaID cannot be found
Usage
@DB2Schema is intended to be used with Query Views, where a DB2 SQL query returns a result set for
display. This SQL query is an evaluated formula, and may incorporate @functions in the query formula,
the evaluation of which results in the text string of the SQL executed in DB2. To SELECT from a Domino
Access View (DAV) within the current db2nsfs schema, the DAV table must be qualified by the schema
name. Otherwise, DB2 uses the accessing users name as the schema name. @DB2Schema allows the
schema name to be dynamically specified within a query formula.
This function also works in all contexts where @function use is supported, including view selection
formulas, and column formulas.
Syntax
@DbColumn( class : cache ; server : database ; view ; columnNumber )
Note: The separator between the class and cache arguments as well as the server and database
arguments is a colon; the rest of the separators are semi-colons.
Parameters
class
Text. Indicates what type of database you are accessing. You can indicate a Domino database with either
Notes or (null string).
cache
String argument. Optional. In the initial lookup, specify either or NoCache. If the former case,
subsequent lookups to the same data source, you can specify ReCache.
v (null string) caches the results of the lookup. Each subsequent lookup to the same location (within
the same Domino session and so long as the database executing this lookup remains open) reuses that
data until you specify ReCache. Cached data improves performance and may be a good choice for
stable data.
v ReCache refreshes the cache with the latest data from the database. If you want to ensure that this
lookup gets the latest information, specify this option.
v NoCache gets the results of the lookup from the database; no cache is used. If you want to ensure
that Domino retrieves the latest information for every lookup, specify this option.
server : database
Text list. The server location and file name of the database. See Specifying the server and database.
view
Text. The name of the view in which to search. The view name must exactly match the full name of the
view as specified in the View properties (you can omit the alias). If the view cascades from another name
on the menu, include that name, too. See Specifying the view name.
columnNumber
Number. The column number within the view. Because Lotus Notes/Domino looks up information in the
view based on column numbers, you can only retrieve data that actually appears in the view. See
Specifying the column number.
Text, numbers, date-time, or text list. The values found in the view column that you indicated. See
Accessing the values found, later in this chapter.
Lotus Domino searches for replicas in this order, using the first replica it encounters:
v Workspace
v If there is one replica on your workspace, Lotus Domino uses it.
v If there are multiple, stacked replicas on your workspace, Lotus Domino uses the replica on top of the
stack.
v If there are multiple, unstacked replicas on your workspace, Lotus Domino looks for an icon matching
your current server and uses that. If none of the icons matches your current server, Lotus Domino uses
the icon that was added to your workspace first.
v Current server
v Locally (your hard disk)
Once a replica is located, its added to your workspace to save time on future lookups.
Notes
v To avoid typing errors in the replica ID, choose File - Database - Design Synopsis and select
Replication. You can then copy the replica ID from the synopsis and paste it into your formula.
v If your database is located in a DOS or OS/2 subdirectory, such as MAIL\MINE.NSf, put a double
backslash between the directory and the database name, as in MAIL\\MINE.NSF, because formulas
treat backslashes as quote characters.
When you reference this view with @DbColumn, you can simply use the LName synonym, enclosed in
quotation marks:
"LName"
Use the following method to calculate the column number for lookup purposes:
1. Count the columns in the view, from left to right. Look at the view in design mode to make sure that
you see all the columns, including columns used for sorting or categorizing the view.
2. Discount all columns that display a constant value, such as Submitted by: or 32. If a column
contains a formula that happens to return the same result for every document, it is not considered a
constant, so be sure to include it in your column count.
3. Discount all columns that consist solely of the following @functions: @DocChildren,
@DocDescendants, @DocLevel, @DocNumber, @DocParentNumber, @DocSiblings, @IsCategory,
@IsExpandable.
4. Now recount the columns, working from left to right.
This revised column number is the value to specify in the lookup formula.
If you specify a nonexistent column, you dont get an error, but rather a null value.
@DbColumn can return no more than 64K bytes of data. Use the following equations to determine how
much of your data can be returned using @DbColumn.
Usage
@DbColumn is intended mainly for use with keyword formulas. Instead of hardcoding a list of
keywords and then periodically updating that list by reediting the form containing the keyword field,
@DbColumn allows you to dynamically retrieve a list of values from a database view or table.
This function does not work in column or selection formulas, or in mail agents.
Note: Agents running on R5 or earlier servers can only access target databases stored on the same server
as the source database. In addition, the agent signer must have at least Reader access to the target
database. The use of a replica id in the acl is still supported in Release 6 and later. If the agent signer is
not available in the acl of a pre-Release 6 database and the replica id is, the replica id is used instead.
(You grant access to the source database by adding the replica id of the source database, for example
85255CEB:0032AC04, to the ACL of the target database and assigning it Reader access or higher.)
Language cross-reference
ColumnValues property of LotusScript NotesDocument class
Note: @DbColumn can only retrieve data; it cant add, delete, or modify data.
Syntax
@DbColumn( ODBC : cache ; data_source ; user_ID1 : user_ID2 ; password1 : password2 ; table ; column :
null_handling ; Distinct : sort )
Parameters
ODBC
String argument. Indicates that you are accessing an ODBC data source.
cache
data_source
Text. The name of the external data source being accessed. A data source indicates the location of one or
more database tables.
user_ID1 : user_ID2
Text list. The user IDs needed to connect to the external database. You may need up to two IDs,
depending on the DBMS being accessed.
password1 : password2
table
column
Text. The name of the column from which data is being retrieved.
null_handling
Text. Specifies how null values are treated when the data is retrieved.
Distinct
String argument. Optional. Removes duplicate values from the list before returning data.
sort
Return value
valuesFound
Text, number, date-time, or a list of these types. The values found in the columnyou indicated.
Note: If you use the option button or the check box user interface for a keywords field, Lotus Domino
updates the keyword list only when the document is composed or is loaded for editing. If you use the
Standard user interface for the list, the keyword list is updated every time the document is recalculated.
@DbLookup can access data sources that have already been registered in the ODBC.INI file (or similar
registry on platforms other than Windows).
Instead of storing the IDs in the @DbColumn formula, you can replace them with null strings (). If an
ID is required, the user will be prompted for it. This is useful when you do not want other designers to
see IDs, or when you want users to enter their own IDs when accessing external data. However, you
must include IDs and passwords in formulas that run automatically (such as an agent) because these
formulas dont prompt for information.
The user IDs and passwords for accessing a data source are required only once per Domino database
session, as long as that database remains open. If the user opens another Domino database and executes a
formula that accesses the same data source, the user ID and password will be required again.
Password parameters are necessary only when ID parameters are specified. Like IDs, passwords can
either be stored in the @DbColumn formula, or prompted for by substituting the null string. If the
database password is null, you can omit it from the formula.
Table can also refer to a database view in the DBMS being accessed.
To control how null values are handled, specify one of the following, appended to the column parameter
with a colon:
v Fail generates this error message if the column of data contains any null values:
Null values found - canceling @Db function
No data is returned with the message.
v Discard discards the null values, thus shortening the returned list of values. If one or more values are
discarded when the @DbColumn formula is executed, you see this message on the status bar:
Caution: NULL values discarded from @Db list.
v Replacement value specifies a replacement value for null values. The replacement value must be a
quoted string, but if the column is numeric or date-time, the string must be convertible to that type.
If your formula includes a sort string argument, the list of values to be returned is sorted before the
replacement values are inserted. During sorting, all null values are placed at the beginning of the list
for an ascending sort; and at the end for a descending sort. They are not replaced until sorting is
complete. This can result in a list that has some values sorted incorrectly. For example, if you specify
zzz as your replacement value, all the zzz values will appear at the beginning of the list, even if
you sorted it in ascending order.
If one or more values are replaced when the @DbColumn formula is executed, you see this message on
the status bar:
Caution: NULL value replaced with user-defined value in @Db list
Generally, the replacement value should be one that is not likely to appear in the list as valid data; for
example, if the column is text, your replacement value might be *** so that you can easily find those
values in Lotus Domino.
Specifying Distinct
The Distinct string argument is similar to @Unique in Lotus Domino, except that Distinct ensures that
duplicate values are removed before the data is returned. Using Distinct instead of @Unique has two
advantages:
v The formula operates more quickly because the additional work is performed outside of Lotus
Domino.
v You can potentially retrieve a larger amount of useful data into Domino -- since the duplicate values
are removed at the back-end, more unique values can be returned to Lotus Domino.
Note: Distinct is not supported by all ODBC drivers. If there are null values in the data and you specify
Distinct, one null is usually returned.
Specifying sort
If you use the Distinct string argument, you can append the sort parameter to it with a colon. Use one of
these keywords for the sort parameter to specify sorting of the return values:
v Ascending sorts the list in ascending order.
v Descending sorts the list in descending order.
Note: The sort keywords are not supported by all ODBC drivers. If you attempt to use both Ascending
and Descending in your formula, you see an Invalid argument message.
@DbColumn can return no more than 64KB of data. Use the following equations to determine how much
of your data can be returned with @DbColumn.
v For lookups that return text:
2 + (2 * number of entries returned) + total text size of all entries
Each text string is limited to 511 bytes; if only one text string is returned, it is limited to 64KB.
v For lookups that return numbers or dates:
(10 * number of entries returned) + 6
the @DbColumn formula is disabled. The user will not see an error message; the formula fails to execute.
This applies to @DbColumn only when you use it with ODBC.
Usage
@DbColumn is intended mainly for keyword formulas. Instead of hardcoding a list of keywords and
then periodically updating that list, @DbColumn allows you to dynamically retrieve a list of values from
an external database table.
This function only works in Web applications if the remote server hosting the table from which data is
being retrieved exists on the same machine as the Domino server, which is rarely the case.
Language cross-reference
GetValue method of Lotus Connectors ODBCResultSet class
Use @DbColumn to retrieve the entire contents of the Color column (column 3):
@DbColumn("OBDC";"INVENTORY";"";"";"UNIFORMS";"Color")
Values in the resulting list appear just as they were encountered in the database; they are not sorted
and duplicate values are retained:
Red:Green:Red:Yellow
2. This example uses the sample pubs database that is included with Microsoft SQL Server. The
formula uses the ODBC SQL Server driver to access the database, locate the table called authors that
is owned by user dbo, and then retrieve the list of names in the au_lname column. The author
names are sorted in ascending order; null values are discarded.
@DbColumn("ODBC";"PUBLISHERS";"dbo";"vanilla";
"dbo.authors"; "au_lname":"Discard";"Ascending")
Syntax
@DbCommand( Domino ; ViewNextPage )
Parameters
Domino
String argument. Indicates that you want to access a Domino data source.
ViewNextPage
ViewPreviousPage
FolderList
String argument. Indicates that you want to display a list of the names of folders in the database that are
accessible from the Web.
promptString
String. Optional. Use only if including FolderList string argument. String to display as the first choice
in a Listbox field. If you want the first choice in the list to be Select a folder, specify:
@DbCommand("Domino" ; "FolderList" ; "Select a folder")
foldersToExclude
Textlist. Optional. Use only if including FolderList string argument. Names of the folders you do not
want to display in the listbox field. If you do not want the MyStuff and Problems folders to be
included in the list, specify:
@DbCommand("Domino" ; "FolderList" ; "Select a folder" ; "MyStuff" : "Problems")
Usage
You cannot use this function to access a Domino data source in the Notes client.
Use the FolderList string argument with the @DbCommand in a selection formula for a Listbox field that
is set to Use formula for choices to display a list of available folders in a Web application. If no folders
exist, the Listbox field is empty when it displays and the promptString does not display in it either.
You can use the FolderDocuments @command with the FolderList string argument to copy or move a
selected document in an embedded view that has HTML selection enabled into the folder selected from
the Listbox field. To do so, complete these steps:
The ViewNextPage and ViewPreviousPage string arguments are useful when your form has an
embedded view that contains several documents. By adding Next and Previous actions to the form that
contains @DbCommand functions with these keywords, you can display the documents in manageable
chunks. Set the Embedded View Properties box options as follows:
1. Set the Web access Display setting to Using HTML.
2. Deselect Use default.
3. Select a number in the Lines to display field.
Note: @DbCommand only works with ODBC data sources and only with SELECT statements. If used
with statements that dont retrieve a result set, @DbCommand simply transmits the statement. Use the
ODBC capabilities of LotusScript for more extensive interaction.
Parameters
ODBC
String argument. Indicates that you are accessing an ODBC data source.
cache
String argument. Optional. In the initial lookup, specify either or NoCache. If the former case,
subsequent lookups to the same data source, you can specify ReCache.
v (null string) caches the results of the lookup. Each subsequent lookup to the same location (within
the same Domino session and so long as the database executing this lookup remains open) reuses that
data until you specify ReCache. Cached data improves performance and may be a good choice for
stable data.
v ReCache refreshes the cache with the latest data from the database. If you want to ensure that this
lookup gets the latest information, specify this option.
data_source
Text. The name of the external data source being accessed. A data source indicates the location of one or
more database tables. See Specifying the data source.
user_ID1 : user_ID2
Text list. The user IDs needed to connect to the external database. You may need up to two IDs,
depending on the DBMS being accessed. See Specifying IDs and passwords.
password1 : password2
Text list. The passwords required by the user ID(s). See Specifying IDs and passwords.
command_string
Text. An SQL statement, command statement, or name of a procedure to be executed. See Specifying a
command string.
null_handling
Text. Specifies how null values are treated when the data is retrieved. See Specifying null handling.
Return value
valuesFound
Text, number, date-time, or a list of these types. The values returned by the command_string. See
Accessing values found.
@DbCommand can access data sources that have already been registered in the ODBC.INI file (or similar
registry on platforms other than Windows).
Instead of storing the IDs in the @DbCommand formula, you can replace them with null strings (). If an
ID is required, the user will be prompted for it. This is useful when you do not want other designers to
see IDs, or when you want users to enter their own IDs when accessing external data. However, you
must include IDs and passwords in formulas that will run automatically (such as an agent) because these
formulas dont prompt for information.
The user IDs and passwords for accessing a data source are required only once per Domino database
session as long as that database remains open. If the user opens another Domino database and executes a
formula that accesses the same data source, the user ID and password will be required again.
Password parameters are necessary only when ID parameters are specified. Like IDs, passwords can
either be stored in the @DbColumn formula, or prompted for by substituting the null string. If the
database password is null, you can omit it from the formula.
Note: For complex connections, additional ID and password parameters may be required to connect to
the data source.
A date-time value must be entered in the format of the database, not that of Lotus Domino; for example,
use 1996-01-31-12.00.00 for DB2/2, not 1996-01-31-12:00:00.
the @DbCommand formula is disabled. The user will not see an error message; the formula fails to
execute.
Usage
@DbCommand is useful for testing a non-equal relationship (such as lessthan), or for testing multiple
conditions at the same time. To use @DBCommands, pass a command to the backend database for
processing.
Write the selection statement in SQL, and then use @DbCommand to pass that statement to the DBMS for
processing; @DbCommand then returns the requested data.
For Web applications, you can use this function only with the syntax:
@DbCommand("Domino";"ViewNextPage")
or
@DbCommand("Domino";"ViewPreviousPage")
to create a link to the next or previous page in a view. You cannot use @DbCommand in any other
context with Web applications.
@DbExists
Given a server and file name, or replica ID, indicates whether the specified database exists.
Syntax
@DbExists( server : file )
Parameters
server
Text. The name of the server. Use an empty string () to indicate the local computer.
file
Text. The path and file name of the database. Specify the database path and file name using the
appropriate format for the operating system.
replicationID
Return value
flag
Number.
v Returns 1 (True) if the database exists.
v Returns 0 (False) if it does not exist.
Usage
This function does not work in column or selection formulas, or in agents that run on a server (mail and
scheduled agents).
Language cross-reference
Open method of LotusScript NotesDatabase class
Syntax
@DbLookup( class : cache ; server : database ; view ; key ; fieldName ; keywords ) or @DbLookup( class : cache
; server : database ; view ; key ; columnNumber ; keywords )
Note: The separator between the class and the cache string arguments as well as the server and database
are colons; the rest of the separators are semicolons.
Parameters
class
Text. Indicates what type of database you are accessing. You can indicate a Domino database with either
or Notes.
cache
String argument. Optional. In the initial lookup, specify either or NoCache. If the former case,
subsequent lookups to the same data source, you can specify ReCache.
v (null string) caches the results of the lookup. Each subsequent lookup to the same location (within
the same Domino session and so long as the database executing this lookup remains open) reuses that
data until you specify ReCache. Cached data improves performance and may be a good choice for
stable data.
v ReCache refreshes the cache with the latest data from the database. If you want to ensure that this
lookup gets the latest information, specify this option.
server : database
Text list. The server location and file name of the database. See Specifying the server and database.
view
key
Text. Determines which document is actually read in order to retrieve a value. A documents key is the
value displayed in the first sorted column within the view. See Specifying a key.
fieldName
Text. The name of the field from which the data will be retrieved, once the correct document(s) has been
identified. See Specifying a field name.
columnNumber
Number. When you use a column number, Domino finds all documents in the view that match the
specified key, and returns whatever value is displayed in the indicated column for each of those
documents, regardless of the formula used to display the data. See Specifying the column number.
keywords
Return value
valuesFound
Text, numbers, date-time, or text-list. The values found in the fieldName or column you indicated, or the
UNID of the document. See Accessing the return values below.
Notes
v To avoid typing errors in the replica ID, choose File - Database - Design Synopsis and select
Replication. Then copy the replica ID from the synopsis and paste it into your formula.
v If your database is located in a DOS or OS/2 subdirectory, such as MAIL\MINE.NSF, put a double
backslash between the directory and the database name, as in MAIL\\MINE.NSF because formulas
treat single backslashes as escape characters.
Specifying a view
You can specify a view parameter using either the full name of the view (or folder) or its synonym. For
example, if your Last Name view is cascaded from By Author in the View menu, and has the synonym
|LName, it looks like this in the view InfoBox:
By Author\Last Name|LName
When you reference this view with @DbLookup, you can just use the LName synonym, enclosed in
quotation marks:
LName
If the view name doesnt have a synonym, you use the By Author name plus the Last Name cascade,
again enclosed in quotation marks (but without the synonym). And since the view name is used in a
formula, the \ must be preceded with an additional \ to ensure that Lotus Domino interprets it
correctly:
By Author\\Last Name
Specifying a key
You can only test for values that match the key (equality); there is no way to specify a different operator
such as < (lessthan).
In addition to specifying a constant as the key to be matched, you can also use the value of an editable
field. For example, you could create a ContactInfo form that contains two fields: a contactName field and
a lookupComments field. You want a user to be able to enter a contact name in the contactName field
and have the lookupComments field display a list of comments associated with the contact that the user
supplied. To do so, you could make the contactName field an editable text field (or a choice list field such
as a Dialog list field). The lookupComments field could contain the following code as its Input validation
formula:
@DbLookup(:NoCache;Sales:Customers.nsf;ContactList;contactName;Comments)
When a user enters or chooses the customer name, Susie Queue, for instance, in the contactName field
of the ContactInfo form and presses F9 to refresh the document, the formula in the lookupComments
field performs these tasks:
By specifying the field contactName as the key, whenever the @DbLookup formula is executed, the
current value of the contactName field is used as the lookup criterion.
The match between the lookup key and the value in the sort column must be exact -- capitalization
doesnt matter, but spacing and punctuation must be precise. The match must be complete unless you
specify the [PARTIALMATCH] keyword.
The view must contain a sorted column in order for the lookup to work; otherwise a null value is
returned. Results are not accurate for a multi-value field that is sorted but not categorized.
Some of the documents matching the key may not even contain the specified field if they were created
using different forms.
For example, if your view is categorized by product ID and you specify 01776 as the lookup key and 2
as the column, Lotus Domino returns whatever is displayed in column 2 for all documents categorized
under product ID 01776.
To specify a columnNumber parameter, you count the views columns from left to right, with the leftmost
column being number 1. Because of the way Lotus Domino indexes views, however, not every column is
counted for the lookup.
Use this method to calculate the column number for lookup purposes:
1. Count the columns in the view, from left to right.
Be sure you dont miss any columns, for example, a column used for sorting or categorizing the view
may not show up. Look at the view in design mode to make sure you see all its columns.
2. Discount all columns that display a constant value, such as 32 or Submitted by: . If a column
contains a formula that happens to return the same result for every document, it is not considered a
constant so be sure to include it in your column count.
3. Discount all columns that consist solely of the following @functions: @DocChildren,
@DocDescendants, @DocLevel, @DocNumber, @DocParentNumber, @DocSiblings, @IsCategory,
@IsExpandable.
4. Now recount the columns, working from left to right.
This revised column number is the value to specify in the lookup formula.
@DbLookup can return no more than 64KB of data. Use the following equations to determine how much
of your data can be returned with @DbLookup.
Usage
This function does not work in column or selection formulas, or in mail agents.
When you use @DbLookup in an agent, it can access data in a target database that is running on either
the same server as the one hosting the source database or another server. The agent signer must have at
least Reader access to the target database.
Note: Agents running on R5 or earlier servers can only access target databases stored on the same server
as the source database. In addition, the agent signer must have at least Reader access to the target
database. The use of a replica id in the acl is still supported in Release 6. If the agent signer is not
available in the acl of a pre-Release 6 database and the replica id is, the replica id is used instead. (You
grant access to the source database by adding the replica id of the source database, for example
85255CEB:0032AC04, to the ACL of the target database and assigning it Reader access or higher.)
Note: For the DeliverTo field, Marys name is determined when the document is composed, using
@UserName.
2. Using the Name & Address Book again, you want to retrieve a list of office telephone numbers for
everyone in the Purchasing department.
You could use @DbLookup with the key Purchasing to retrieve the OfficePhoneNumber field, and
Notes would return the telephone number for every employee with Purchasing entered in the
Department field of their Person record. The phone numbers are returned as a text list, using the
selected multivalue separator for the field.
3. This formula returns the value stored in the Status field of the Virus Check document, which is
accessed via the In Progress view of the PROJECTS.NSF database stored in the SMITH subdirectory
on the RESEARCH server. The information will not be cached, so if this formula is evaluated again
during the same Notes session, a new lookup will be performed to ensure that the status retrieved is
up to date.
@DbLookup("":"NoCache";"RESEARCH":"SMITH\\PROJECTS.NSF"; "In Progress";"Virus Check";"Status")
Note: @DbLookup can only retrieve data; it cant add, delete, or modify data.
Syntax
@DbLookup( ODBC : cache ; data_source ; user_ID1 : user_ID2 ; password1 : password2 ;
table ; column : null_handling ; key_column ; key ; Distinct : sort )
Parameters
ODBC
String argument. Indicates that you are accessing an ODBC data source.
cache
String argument. Optional. In the initial lookup, specify either or NoCache. If the former case,
subsequent lookups to the same data source, you can specify ReCache.
data_source
Text. The name of the external data source being accessed. This name is specified as the dsn (data source
name) in the Data Source Administrator or the odbc.ini file. A data source indicates the location of one or
more database tables. See Specifying the data source.
user_ID1 : user_ID2
Text-list. The user IDs needed to connect to the external database. You may need up to two IDs,
depending on the DBMS being accessed. See Specifying IDs and passwords.
password1 : password2
Text list. The passwords required by the user IDs. See Specifying IDs and passwords.
table
column
Text. The name of the column from which data is being retrieved.
null_handling
Text. Specifies how null values are treated when the data is retrieved. See Specifying null handling.
key_column
key
Text, number, or date-time, or a list. The value to be looked up in key_column. Use the Notes type that
agrees with the type of the key column in the data source.
Distinct
String argument. Optional. Removes duplicate values from the list before returning data. See Specifying
Distinct.
sort
Return value
valuesFound
Text, number, date-time, or a list of these types. The values found in the columnyou indicated. See
Accessing the values found, later in this chapter.
Note: If you use the option button or the check box user interface for a keywords field, Lotus Domino
updates the keyword list only when the document is composed or opened for editing. If you use the
Standard user interface for the list, the keyword list is updated every time the document is recalculated.
Instead of storing the IDs in the @DbLookup formula, you can replace them with null strings (). If an
ID is required, the user will be prompted for it. This is useful when you do not want other designers to
see IDs, or when you want users to enter their own IDs when accessing external data. However, you
must include IDs and passwords in formulas that will run automatically (such as an agent) because those
formulas dont prompt for information.
The user IDs and passwords for accessing a data source are required only once per Domino database
session as long as that database remains open. If the user opens another Domino database and executes a
formula that accesses the same data source, the user ID and password will be required again.
Password parameters are necessary only when ID parameters are specified. Like IDs, passwords can
either be stored in the @DbLookup formula, or prompted for by the ODBC driver by substituting the null
string. If the database password is null, you can omit it from the formula.
For example:
"dbo.author"
Table can also refer to a database view in the DBMS being accessed.
Specify a value using the Notes type that agrees with the key column in the data source. For example,
specify a number or a number-valued expression when the key column is of any numeric type, such as
integer, real, float, or double. If the key is a string (text) value, enclose it in quotation marks. A date-time
value must be entered in the format of the database, not that of Lotus Domino; for example, use
1996-01-31-12.00.00 for DB2/2, not 1996-01-31-12:00:00.
Together, the key column and the key form the where clause of a selection statement:
"SELECT column WHERE key_column = key"
The ODBC Application Interface always tests for equality and only returns data from records where the
value in the key column exactly matches the key. To test whether the value in the key column matches
one of several possible values, format the key value as a list, separating items with colons as in
Red:Blue:Green. This acts like an OR operation, returning data from all records where the value in
the key column matches Red OR Blue OR Green. To perform an AND operation or to test for
inequality, use @DbCommand to pass the appropriate command string to the DBMS. Also use
@DbCommand to pass the appropriate command string if the key is a time-date value, because
@DbLookup does not always convert the time-date value to the correct format for time-dates in the
DBMS command language.
If you cannot get @DbLookup to return the correct values due to typing or other problems, try using a
SELECT statement in @DbCommand.
Specifying Distinct
The Distinct string argument is similar to @Unique in Lotus Domino, except that Distinct ensures that
duplicate values are removed before the data is returned to Lotus Domino. Using Distinct instead of
@Unique has two advantages:
Note: Distinct is not supported by all ODBC drivers. If there are null values in the data and you specify
Distinct, one null is usually returned.
Specifying sort
If you use the Distinct string argument, you can append the sort parameter to it with a colon. Use one
these keywords for the sort parameter to specify sorting of the return values:
v Ascending sorts the list in ascending order.
v Descending sorts the list in descending order.
Note: The sort keywords are not supported by all ODBC drivers. If you attempt to use both Ascending
and Descending in your formula, Lotus Domino displays an Invalid argument message.
@DbLookup can return no more than 64KB of data. Use the following equations to determine how much
of your data can be returned with @DbLookup.
v For lookups that return text:
2 + (2 * number of entries returned) + total text size of all entries
Each text string is limited to 511 bytes; if only one text string is returned, it is limited to 64KB.
v For lookups that return numbers or dates:
(10 * number of entries returned) + 6
the @DbLookup formula is disabled. The user will not see an error message; the formula fails to execute.
This applies to @DbLookup only when you use it with ODBC.
Usage
@DbLookup is intended mainly for keyword formulas. Instead of hardcoding a list of keywords and
then periodically updating that list, @DbLookup lets you dynamically retrieve a list of values from an
external database table.
@DbLookup cant be used in mail agents, although it does work in paste agents. This function only
works in Web applications if the remote server hosting the table from which data is being retrieved exists
on the same machine as the Domino server, which is rarely the case.
To retrieve the entire contents of the Color column (column 3) for all records where the first sorted
column (column 1, Item) contains Shirt or Trousers:
@DbLookup("ODBC"; "INVENTORY"; ""; ""; "UNIFORMS"; "Color"; "Item"; "Shirt" : "Trousers")
Since multiple records contain at least one of the keys, the result is a list:
Red:Yellow
Values in the resulting list appear just as they were encountered in the database; they are not sorted
and duplicate values are retained.
2. This example uses the sample pubs database that is included with Microsoft SQL Server. The
formula uses an ODBC driver to access the data source called PUBLISHERS and locate the table
called authors that is owned by user dbo. In this table, the values in the state column are
compared with the values CA and TN. For every record whose state field contains either CA or
TN, the values stored in the au_lname field are returned. The author names are sorted in
ascending order; null values are discarded.
@DbLookup("ODBC";"PUBLISHERS";"dbo";"vanilla";
"dbo.authors";"au_lname":"Discard";"state";
"CA":"TN";"Ascending")
@DbManager
Returns a list of users, groups, and servers who currently have Manager access to the database. In a
window title formula, only the name of the first manager listed in the ACL is displayed.
Syntax
@DbManager
Return value
managers
Text or text list. The users, groups, and servers that have manager access.
Language cross-reference
Managers property of LotusScript NotesDatabase class
Examples: @DbManager
1. This example returns Gerald Brown if Gerald Brown is the only user with Manager access to the
current database.
@DbManager
2. This example returns Gerald Brown;Supervisors if Gerald Brown and a group called Supervisors
have Manager access to the current database.
@DbManager
@DbName
Returns the name of the current Domino server and database.
Syntax
@DbName
Return value
server ; path
Usage
Be careful when using @DbName in a column formula. If you build a view, then move the database
within the file directory, thus changing its path, you must force a rebuild of the view (Cntl+Shift+F9) for
the function to display the updated database information.
Language cross-reference
FileName property of LotusScript NotesDatabase class
@DbTitle
Returns the title of the current database.
Syntax
@DbTitle
Return value
title
Language cross-reference
Title property of the LotusScript NotesDatabase class
Examples: @DbTitle
This form action formula uses @DbTitle to let the user create and send an e-mail memo to the author of
the current document. @DbTitle is used in the memos Subject.
return:=@Char(13);
memobody:=@Prompt([OKCANCELEDIT]; "Mail message";
"Enter the contents of your mail message below." + return + "It will be sent to " + From + "."; "" );
@MailSend(From; ""; ""; "Your posting in " + @DbTitle; "";
memobody:return; [IncludeDoclink])
Syntax
@DDEExecute( conversationID ; command )
Parameters
conversationID
The conversationIDis returned by the @DDEInitiate function, which must precede the use of
@DDEExecute. Use your own variable name; thats how you pass the conversation ID between Lotus
Domino and the other application. If the conversation ID is invalid, Lotus Domino returns an error. See
@IsError.
command
Text. The command must be a text string that adheres to the syntax rules of the receiving application (see
that applications documentation). Enclose the command in quotation marks so it can be passed intact to
the DDE application; that application will then interpret it as a DDE command.
Return value
acknowledgment
Number.
v Returns @True (1) if the DDE command is successfully executed
v Returns @False(0) if not
v Returns an error if the conversation ID is invalid
Usage
This function is intended for use primarily in field formulas, agents, and toolbar buttons. It does not
work in column or selection formulas, and is not intended for use in window title or form formulas.
Since the Macintosh does not support DDE, these commands will not work on Macintosh workstations.
In addition, the format of the DDE commands may vary somewhat with each platform or application.
then any formula involving @DDE functions is disabled. The user doesnt see an error message; the
formula fails to execute.
You can have up to 10 DDE conversations running concurrently, although under normal circumstances
you should only have one conversation running at a time. Be sure to terminate all DDE conversations
once theyre completed, or you may run out of sessions and be unable to initiate more conversations
when needed.
For details on how to access data in external applications, see, Including OLE Objects in Applications in
the Application Development with Domino Designer book.
Initiates a conversation between Domino and 123. This statement specifies which worksheet to use
(BUDGET95.WK3) and stores the conversation ID in the variable Conv_ID. Note that the specified file
must be open before the @DDEInitiate is executed.
@If (@IsError(Conv_ID); @Do(@Prompt([Ok];"Error";
"Unable to initiate conversation"); @Return(""));
Determines whether the DDE conversation was successfully initiated. If it was, the formula continues; if
it wasnt, a message appears, and the formula stops executing.
@Do(@DDEPoke(Conv_ID;"A:B6";@Text(Amount));
Converts the contents of the numeric Amount field to text, and then passes that value to cell A:B6 in the
123 worksheet. The value must be converted to text because only text can be passed via DDEPoke.
@DDEExecute(Conv_ID;"[RUN(\"{Goto}A:B6~\")]");
Passes the Range, Format, Currency command to 123; cell A:B6 is now formatted for currency values.
@DDEExecute(Conv_ID;"[RUN(\"{Goto}A:B10~{EditCopy}\")]");
Passes the Goto and Edit Copy commands to 123; cursor is moved to cell A:B10 within the worksheet
and the value stored in that cell is copied to the Windows Clipboard.
@DDETerminate(Conv_ID);
The contents of the Clipboard (the value from cell A:B10) are pasted into that field.
@DDEInitiate
Initiates a conversation with a DDE server, and returns the conversation ID.
Parameters
application
Text. The name of the application you want to initiate a DDE conversation with. This application must be
launched before you call @DDEInitiate. The values for applicationand topicvary from one application to
another; the appropriate values can usually be found in the index for the applications documentation,
under DDE.
topic
Text. The data file you want to use. This file must be opened before you call @DDEInitiate.
Return value
conversationID
This ID identifies the particular DDE conversation so you can pass commands and data to it with
@DDEExecute and @DDEPoke, and eventually terminate the conversation with @DDETerminate. Returns
an error if the conversation cannot be initiated. See @IsError.
Usage
It is intended for use primarily in field formulas, agents, and toolbar buttons. Since the Macintosh does
not support DDE, these commands will not work on Macintosh workstations. This function does not
work in column or selection formulas, and is not intended for use in window title or form formulas.
then any formula involving @DDE functions is disabled. The user doesnt see an error message; the
formula fails to execute.
You can have up to 10 DDE conversations running concurrently, although under normal circumstances
you should only have one conversation running at a time. Be sure to terminate all DDE conversations
once theyre completed, or you may run out of sessions and be unable to initiate more conversations
when needed.
Initiation failures
If the conversation cannot be initiated, @DDEInitiate will return an error. See @IsError. Below are some
reasons why the initiation could fail:
v The workstation operating system does not support DDE (Macintosh).
v The DDE application youre trying to set up a conversation with is not running. The specified file is
not open.
v The DDE application is running, but the specified topic is not open or the application does not support
the topic specified with @DDEInitiate.
v The DDE application is running, but the specified file does not open.
v The maximum number of concurrent DDE conversations has been reached (currently, the maximum is
10).
Syntax
@DDEPoke( conversationID ; location ; data )
Parameters
conversationID
location
Text. The name of the location where you want to place the data. The location must be a cell, range, or
field name; enclose it in quotation marks.
data
Text. Optional. The data you want to place at location. If you want to pass the contents of a nontext field,
use @Text to convert it to text first. If data is a text list, only the first value in the list gets passed. If you
omit data, Domino passes the contents of the Windows Clipboard to the receiving application. If you
supply the data as a parameter, either enclose it in quotation marks or specify a Domino field name.
Usage
It is intended for use primarily in field formulas, agents, and toolbar buttons. Since the Macintosh does
not support DDE, these commands will not work on Macintosh workstations. This function does not
work in column or selection formulas, and is not intended for use in window title or form formulas.
then any formula involving @DDE functions is disabled. The user doesnt see an error message; the
formula fails to execute.
@DDETerminate
Terminates the conversation with a DDE application.
Syntax
@DDETerminate( conversationID )
Parameters
conversationID
Return value
status
v Returns an error if the conversationID is invalid
v Returns nothing if the conversationID is valid
See @IsError.
Usage
It is intended for use primarily in field formulas, agents, and toolbar buttons. Since the Macintosh does
not support DDE, these commands will not work on Macintosh workstations.This function does not work
in column or selection formulas, and is not intended for use in window title or form formulas.
then any formula involving @DDE functions is disabled. The user doesnt see an error message, the
formula fails to execute. Be sure to terminate all DDE conversations once theyre completed, or you may
run out of sessions and be unable to initiate more conversations when needed.
DEFAULT
A reserved word that does one of the following:
v Assigns a default value to a field.
v Says that for the duration of the computation of this formula, if a document does not have this field,
act as though it does with this as its value.
v Allows you to assign values that provide dynamic defaults to fields.
Syntax
DEFAULT variableName := value ;
Usage
This reserved word works in any formula.
Use DEFAULT once in a formula. If this keyword occurs multiple times in a formula, the first occurrence
is effective and subsequent occurrences have no effect.
Note: Pre-R6 behavior differs: if a formula contains multiple occurrences of DEFAULT, the last occurrence
is effective.
Language cross-reference
Let statement of LotusScript language
Examples:DEFAULT
These two formulas display the value in the field named KeyThought, if that field exists; otherwise, the
value in the field Topic is displayed. Using DEFAULT lets you write a simpler formula that is less prone
to error, and easier for others to understand.
and
DEFAULT KeyThought := Topic;
KeyThought;
@DeleteDocument
Deletes the current document.
Syntax
@DeleteDocument
Usage
This function works only in agents.
Language cross-reference
DeleteDocument URL command
Examples: @DeleteDocument
This example deletes those documents where the Status field equals Closed.
FIELD Status:=@If(Status="Closed";@DeleteDocument;Status)
@DeleteField
Deletes the value of an editable field.
Syntax
FIELD fieldName := @DeleteField
Usage
This function works in agent, view action, and toolbar button formulas.
If the field has a default value, the default value is reinstated after this function deletes the current value.
Use this function to delete invisible fields from documents, such as fields created using the @SetField
function.
Examples: @DeleteField
This formula creates a field named NewDate and sets it to todays date, then removes the field named
OldDate from the document.
FIELD NewDate:=@Today
FIELD OldDate:=@DeleteField;
@DialogBox
Brings up a dialog box that displays the current document (either open or selected in a view). The dialog
box shares fields with the underlying document. The user interacts with the dialog box as usual, clicking
OK or Cancel when finished.
This function can be used with any form, but its particularly useful with forms that contain a single table
or layout region, because the user can interact with the table or layout region as if it were a dialog box.
Syntax
@DialogBox( form ; [AUTOHORZFIT] : [AUTOVERTFIT] : [NOCANCEL] : [NONEWFIELDS] :
[NOFIELDUPDATE] : [READONLY] : [SIZETOTABLE] : [NOOKCANCEL] :
[OKCANCELATBOTTOM] : [NONOTE] ; title )
Parameters
form
[AUTOHORZFIT]
Keyword. Optional. Scales the dialog box horizontally to fit the first layout region or table on the form.
Otherwise, the dialog box is not scaled horizontally.
[AUTOVERTFIT]
Keyword. Optional. Scales the dialog box vertically to fit the first layout region or table on the form.
Otherwise, the dialog box is not scaled vertically.
[NOCANCEL]
Keyword. Optional. Does not display the Cancel button. Otherwise, the dialog box contains the Cancel
button.
[NONEWFIELDS]
[NOFIELDUPDATE]
Keyword. Optional. Does not pass edits from the fields in the dialog box to the underlying document (for
example, if youre passing the edits somewhere else in a QueryClose script for the dialog box form).
Otherwise, the edits are passed to the underlying form.
[READONLY]
Keyword. Optional. Prohibits writing to the dialog box (for example, if you are using the dialog box to
display a Help screen). Otherwise, the dialog box is read-write. Use of this keyword implies [NoCancel].
[SIZETOTABLE]
Keyword. Optional. Applies [AUTOHORZFIT] and [AUTOVERTFIT] to the first table on the form.
Otherwise, they are applied to the first layout region on the form.
[NOOKCANCEL]
Keyword. Optional. Does not display the OK button. Otherwise, the dialog box contains the OK button.
Using this keyword prevents any changes made in the dialog box from being reflected in the current
document. If you want the current document to be updated, but dont want an OK button to display,
include a hotspot button that executes the RefreshParentNote @command.
[OKCANCELATBOTTOM]
Keyword. Optional. Displays the OK and/or Cancel buttons side-by-side at the bottom right of the dialog
box. Otherwise, the buttons appear stacked at the top right.
[NONOTE]
Keyword. Optional. Allows the @Dialogbox function to be used without requiring a current document. If
a current document exists, it will be ignored. Using this keyword implies [NOFIELDUPDATE] and
[NONEWFIELDS] even if they are not explicitly specified. If the [NONOTE] parameter is not specified, a
current document is required.
title
Return value
none
Only updates changes made to like-named fields on the current form if the dialog box is saved and
closed. See Sharing of field values below.
If the form contains actions on the action bar, they are not displayed in the dialog box.
[AUTOHORZFIT] and [AUTOVERTFIT] allow you to display an entire layout region (no
[SIZETOTABLE]) or table ([SIZETOTABLE]) in a dialog box without displaying the rest of the form. If
the form has more than one layout region or table, the first is used. For best results:
v Use both[AUTOHORZFIT] and [AUTOVERTFIT].
v In the Layout properties box, deselect Show border and select 3D style.
If [AUTOHORZFIT] and [AUTOVERTFIT] are both omitted, the entire form is used and no sizing takes
place. If the form contains no layout region (no [SIZETOTABLE]) or table ([SIZETOTABLE]), the entire
form is used and no sizing takes place.
Language cross-reference
DialogBox method of LotusScript NotesUIWorkspace class
Examples: @DialogBox
1. A form called Profile contains a button whose formula is
@DialogBox("Profile Options"; [AUTOHORZFIT] : [AUTOVERTFIT] )
Both Profile and Profile Options have a field named Comments. When the user clicks the button, the
document is displayed in a dialog box, using the Profile Options form. The dialog box is scaled to fit
the layout region on Profile Options.
The user can interact with the dialog box, for example, by editing the Comments field.
The user clicks OK. The changes made to the Comments field are reflected in the document, if it is in
Edit mode.
2. This formula displays a form named Help screen for reading only.
@Do
Evaluates expressions from left to right, and returns the value of the last expression in the list.
Syntax
@Do( expressions )
Parameters
expressions
Any number of expressions that you want @Do to evaluate. Separate multiple expressions with
semicolons: expression1 ; expression2 ; expression3
Return value
lastExpression
Usage
This function is useful in agents, hotspot buttons, and toolbar buttons and when you want to execute
multiple expressions from within a single @function. It does not work in column or selection formulas.
Examples: @Do
This formula displays a dialog box asking whether the user wants to edit the current document. If the
user selects Yes, another dialog box appears, prompting for the users name. If the user now selects
Cancel, the formula stops execution; if the user enters a name and selects OK, the document is opened in
Edit mode.
If the user selects No at the first dialog box, a different one follows it. This time, a message appears
noting that the user chose not to edit the document, and Lotus Domino navigates to the next document
in the view.
@If(@Prompt([YESNO]; "Question";
"Edit this document?");
@If(@Prompt([OKCANCELEDIT]; "Positive Response";
"You have chosen to edit this document. Select OK if the name below is correct.";
@UserName) != "ERR_CANCEL";
@Command([EditDocument]);@Return(""));
@Do(@Prompt([OK]; "Negative Response";
"You have chosen not to edit this document. Select OK to continue to the next document.");
@Command([NavNext])))
@DocChildren
In a column or window title formula, returns the number of child documents or categories belonging to
the current document or category. Only immediate responses count as children. For example, the
responses to a main document are its children, but the responses to a response document are not.
Parameters
defaultString
Text. Optional. The text to return. If a % is used in the string, it will be replaced with the number of
children documents or categories. Example: % Responses.
zero-string
Text. Optional. The text to return if the document or category has no children, such as No Responses.
one-string
Text. Optional. The text to return if the document or category has just one child, such as One Response.
Return value
The return value depends on how you call @DocChildren:
numChildren
Special text. If @DocChildren is called with no parameters, then the number of child documents
belonging to the current document or category is returned. You cannot convert special text to a number.
childString
Special text. If @DocChildren is called with one or more parameters, it returns the appropriate string,
based on the number of child documents belonging to the current document or category. You cannot
convert special text to a number.
Usage
Use @DocChildren in window title and column formulas, when you want to indicate how many
toplevel responses a particular document has, or how many main documents are within a particular
category. This function does not work in any other formula.
This @function is calculated when the document is opened. Results are undefined in cases where the
document is not opened, such as printing from a view.
You cannot use this function in Web applications, except in column formulas.
Language cross-reference
ChildCount property of LotusScript NotesViewEntry class
Examples: @DocChildren
If there are three direct descendants to a document:
1. This example returns 3.
@DocChildren
@DocDescendants
In a column or window title formula, returns the number of descendant documents or subcategories
belonging to the current document or category. Where @DocChildren only counts direct descendants,
@DocDescendants counts all descendants, regardless of level.
Syntax
@DocDescendants @DocDescendants( defaultString ) @DocDescendants( zerostring ; defaultString )
@DocDescendants( zerostring ; onestring ; defaultString )
Parameters
defaultString
Text. Optional. The text to return. If a % is used in the string, it will be replaced with the number of
descendant documents or categories. Example: % Responses.
zero-string
Text. Optional. The text to return if the document or category has no descendants, such as No
Responses.
one-string
Text. Optional. The text to return if the document or category has just one descendant, such as One
Response.
Return value
The return value can be either special text or text:
numChildren
Special text. If @DocDescendants is called with no parameters, then the number of descendant documents
belonging to the current document or category is returned. You cannot convert special text to a number.
childString
Special text. If @DocChildren is called with one or more parameters, it returns the appropriate string,
based on the number of descendant documents belonging to the current document or category. You
cannot convert special text to a number.
This @function is calculated when the document is opened. Results are undefined in cases where the
document is not opened, such as printing from a view.
You cannot use this function in Web applications, except in column formulas.
Language cross-reference
DescendantCount property of LotusScript NotesView class
Examples: @DocDescendants
If there are three descendants to a document:
1. This example returns 3.
@DocDescendants
2. This example returns 3 Response(s).
@DocDescendants("% Response(s)")
3. This example returns 3 Responses. If there are no responses to the document, the formula returns No
Responses.
@DocDescendants("No Responses";"% Responses")
4. This example returns There are 3 Responses. If the document has one response, the message is 1
Response; if the document has no responses, the message is No Responses.
@DocDescendants("No Responses";"1 Response";
"There are % Responses.")
@DocFields
Returns a list of all the fields in a document.
Syntax
@DocFields
Return value
fields
Text list. Each item in the list is the name of a field on the document.
Usage
This function works in any formula that runs in the context of one or more documents. It does not work
in column and view selection formulas.
After a document is saved, the returned list includes some of the internal Notes fields, such as the Form
field, that is added by Lotus Notes to a form when it is saved or the $Links field, that indicates that the
form contains a link to another document or database.
Examples: @DocFields
1. This example returns Form; result; name; phone if those are the names of the fields in a document.
@DocFields
2. This example returns Yes if used in a field on a form that contains a rich text field containing a link to
a database or document.
@If(@Contains(@DocFields; "$Links"); "Yes"; "No")
3. This example, when used in the postopen event of a form, enables the user to choose a field to alter
from a list of the fields on the form then provide a value to put into the chosen field.
Field fieldtochange := @Prompt([OkCancelEditCombo]; "Edit Fields"; "Please select the field
you want to edit."; ""; @DocFields);
@SetField(fieldtochange;(@Prompt([OkCancelEdit]; "New Value"; "Please enter a new value.";"") )
4. This example, when used in a field on a form, returns the number of fields contained by that form
when it is saved:
@Elements(@DocFields)-2
Subtract 2 from the total number of elements to account for the current field and the Form field,
which is an internal Notes field.
@DocLength
Returns the approximate size of a document in bytes.
Syntax
@DocLength
Return value
length
Usage
This function works in any formula that runs in the context of one or more documents.
The number returned is only an approximation. The actual size of the document may differ for the
following reasons:
v The number accounts for user data only; it does not take into account per document or per field
constants such as static text or formulas.
v The database allocates storage in 64byte increments; a document may not use all of the 64 bytes
allotted to it.
Documents that are open typically use more storage than documents that are closed. The value returned
for @DocLength may vary depending on whether it is running in an open document or a closed
document; for example, a document selected at the view level.
Examples: @DocLength
This example returns 1808 if that is the approximate number of bytes in the document (onepage
document, no enhanced text).
@DocLength
@DocLevel
Returns a text string that represents the level of the document or category.
Syntax
@DocLevel
Return value
level
Special text. The level of the document or category. You cannot convert special text to a number.
Usage
Use @DocLevel in column and window title formulas. If you use it in a window title or field formula, it
will always evaluate to 1 until the document has been saved and reopened. This function does not
work in any other formula.
This @function is calculated when the document is opened. Results are undefined in cases where the
document is not opened, such as printing from a view.
Language cross-reference
ColumnIndentLevel property of LotusScript NotesViewEntry class
Examples: @DocLevel
1. This example of a category returns 1.
@DocLevel
2. This example of a main document in a category returns 2.
@DocLevel
3. This example of a response document in a category returns 3.
@DocLevel
4. This example of a main document that is not in a category returns 1.
@DocLevel
Syntax
@DocLock ( [ options ] )
Parameters
[ options ]
[LOCK]
[UNLOCK]
[STATUS]
Indicates the locked status of the current document. Returns null if the document is not locked or a
textlist of the users who have locked the document if it is locked.
[LOCKINGENABLED]
Indicates if the current database has document locking enabled. Returns 1 (@True) if locking is enabled
and 0 if it is not.
Usage
The current document has to have been saved previously for this function to work properly. The
document must be in Read mode when this function is triggered. Additionally, document locking must
be enabled for the database or you will get the error, Attempted a lock operation on a DB that doesnt
support locking when you try to use the [LOCK], [STATUS], or [UNLOCK] keywords.
Language cross-reference
Lock method of LotusScript NotesDocument class
First, to determine if the current document can be locked, the user checks if document locking is enabled
for the database. When the user clicks the LockingEnabled button, which contains the following code, it
returns 1 to indicate that locking is enabled.
@Prompt([OK];"Checking if document locking is enabled";@DocLock([LOCKINGENABLED]))
If locking is enabled, the user next clicks the Status button, which contains the following code. If it
returns an empty message box, the current document is not locked.
@Prompt([OK];"Checking document status";@DocLock([STATUS]))
Once the user clicks the Lock hotspot button which contains the following code, the administrative server
locks the document. If the user clicks the Status button again, a message box appears that displays the
current users hierarchical name.
@DocLock([LOCK])
If the user then clicks the Unlock hotspot button that contains the following code, the administrative
server unlocks the document. When the user clicks the Status button again, an empty message box
appears.
@DocLock([UNLOCK])
@DocMark
In an agent that runs a formula, indicates whether or not you want to save the changes to a document.
Syntax
@DocMark( [Update] ) @DocMark( [NoUpdate] )
Parameters
[UPDATE]
[NOUPDATE]
Keyword. Marks a document so that changes made to it will not be saved to disk.
Usage
Use @DocMark in any type of agent to indicate if the changes made to a document by the agent should
be saved. This function has no effect in any other formula.
Language cross-reference
Save method of LotusScript NotesDocument class
Syntax
@DocNumber @DocNumber( separator ) @DocNumber( )
Parameters
separator
Text. Optional. Indicates a separator to be used in the document number instead of . (period); must be
one character.
Empty string argument. Optional. Tells the function to return the least significant item of the document
number (in other words, its rightmost component).
Return value
docNum
Special text. The value that represents the document number of the document or category in the view.
You cannot convert special text to a number.
Usage
Use @DocNumber in column or window title formulas. In window title or field formulas, it will evaluate
to 0 until the document has been saved and reopened. This function does not work in any other
formula.
This @function is calculated when the document is opened. Results are undefined in cases where the
document is not opened, such as printing from a view.
You cannot use this function in Web applications, except in column formulas.
Language cross-reference
IndentLevel property of LotusScript NotesViewEntry class
Examples: @DocNumber
1. This example returns 37.1.3 for entry 37.1.3.
@DocNumber
2. This example returns 3713 for entry 37.1.3.
@DocNumber("")
3. This example returns 3 for entry 37.1.3.
@DocNumber("")
Syntax
@DocOmittedLength
Return value
length
Number. The bytes of data that were not replicated. Returns zero if the document has not been truncated,
was truncated previously, or was truncated by a pre-Release 6 server.
Usage
This function works only in databases that are running on and were replicated by a Lotus Domino 6 or
later server.
Documents can be truncated during database replication to save space. One replication setting option, for
instance, enables you to replicate summary data and only 40KB of rich text for each document. In the
resulting replica, you can retrieve the rest of a truncated document by choosing Actions - Retrieve Entire
Document from the menu. @DocOmittedLength enables you to determine how much information (in
bytes) was removed from the document during replication to help you determine if you want to retrieve
it.
This function works in any formula that runs in the context of one or more documents.
The number returned is only an approximation. The actual size of the document may differ for the
following reasons:
v The number accounts for user data only; it does not take into account per document or per field
constants such as static text or formulas.
v The database allocates storage in 64byte increments; a document may not use all of the 64 bytes
allotted to it.
Examples: @DocOmittedLength
1. This example, when used as a column formula, returns the total size of the document:
@DocLength + @DocOmittedLength
@DocParentNumber
In a column or window title formula, returns a string that represents the entry number of the parent view
entry. Both the current view entry and the parent can be either documents or categories.
Syntax
@DocParentNumber @DocParentNumber( separator ) @DocParentNumber( )
Text. Optional. Indicates a separator to be used in the parent document number instead of ..
Empty string argument. Optional. Tells the function to return the least significant item of the parent
document number (in other words, its rightmost component).
Return value
docNum
Special text. The value that represents the document number of the document or category in the view.
You cannot convert special text to a number.
Usage
Use @DocParentNumber in column and window title formulas. If you use it in a field formula or
window title formula, no result is displayed until the document has been saved and reopened. This
function does not work in any other formula.
To determine the number for the current entry, use @DocNumber instead.
You cannot use this function in Web applications, except in column formulas.
Language cross-reference
GetPosition method of LotusScript NotesViewEntry class
Examples: @DocParentNumber
1. This example returns 37.1.3 for the document or category for which the parent is entry 37.1.3.
@DocParentNumber
2. This example returns 3713 for the document or category for which the parent is entry 37.1.3.
@DocParentNumber("")
3. This example returns 3 for the document or category for which the parent is entry 37.1.3.
@DocParentNumber("")
@DocSiblings
In a column or window title formula, returns a string that represents the total number of entries at the
same level as a view entry (document or category). The returned total includes the document itself. For
example, if the document is entry 8.2, and entries 8.1, 8.3, and 8.4 also exist, then there are four document
siblings.
Syntax
@DocSiblings
Return value
numSiblings
Usage
Use @DocSiblings in column and window title formulas. If you use it in a field or window title formula,
it evaluates to 0 until the document has been saved and reopened. This function does not work in any
other formula.
This @function is calculated when the document is opened. Results are undefined in cases where the
document is not opened, such as printing from a view.
You cannot use this function in Web applications, except in column formulas.
Language cross-reference
SiblingCount property of LotusScript NotesViewEntry class
Examples: @DocSiblings
This example returns Response 1 of 4 to Current Vacation Policy if the document is one of four
responses to a document with the string Current Vacation Policy in the Topic field.
@If(@IsNewDoc;"New Document";"Response" + @DocNumber(" ") +
" of " + @DocSiblings + " to " + Topic)
@DocumentUniqueID
The universal ID, which uniquely identifies a document across all replicas of a database. In text format,
the universal ID is a 32-character combination of hexadecimal digits (0-9, A-F).
Syntax
@DocumentUniqueID
Usage
If two documents in replica databases share the same universal ID, the documents are replicas.
This function works in any formula that runs in the context of one or more documents.
To display the UNID, you must convert the result of this function to text, that is, you must specify
@Text(@DocumentUniqueID).
The unique ID is one part of a documents entire ID number. To see a document ID, click the Document
IDs tab of the document properties box. The UNID is on the first two lines following OF (top line) and
ON (second line) in two 8-character segments.
Once created, a documents UNID never changes. If a document is copied and pasted, the pasted
document gets a new UNID.
Every response document has a special field called $Ref that contains the UNID of the parent document.
Examples: @DocumentUniqueID
1. This column formula displays the UNID of each document in the view.
@Text(@DocumentUniqueID)
2. This computed field formula creates a doclink to the current document.
@DocumentUniqueID
3. This Computed when composed field formula in a Response document creates a doclink to the
parent document. In the properties box for the Response form, Formulas inherit values from
selected document must be checked.
@InheritedDocumentUniqueID
4. You want the Project field of a new Response document to match the Project field of the parent
Main Topic document. In the properties box for the Response form, check Formulas inherit values
from selected document. Make Project on the Response form a computed field and give it this
formula:
Project
5. Field inheritance only happens once when the Response is created. However, you want to access the
Main Topic after the Response is created. Create an agent that runs on a schedule, selects all
documents in the database that use the form Response, and runs the following formula:
FIELD Project := @GetDocField($Ref; "Project");
@All
6. This is a long solution to the above problem. Create a hidden view called, for example, By doc ID
with the following selection formula:
SELECT Form = "Main Topic"
The first column is sorted and its formula is:
@Text(@DocumentUniqueID)
Create an agent that runs on a schedule, selects all documents in the database that use the form
Response, and runs the following formula:
FIELD Project := @DbLookup("":""; ""; "By doc ID"; @Text($Ref); "Project");
@All
Each time the agent runs, it performs a lookup in the By doc ID view to find the Main Topic that
is the parent of the current Response (that is, the document with a @DocumentUniqueID that
matches the current documents $Ref field). It then copies the contents of the Project field from the
parent to the child.
@Domain
Returns the name of the current users Domino mail domain listed in the current location document of
the Personal Address Book.
Syntax
@Domain
Usage
This function works in any formula and is useful in formulas that manipulate mail addresses. When a
formula runs on a server, the server is considered the current user, so @Domain returns the name of the
servers domain.
Language cross-reference
GetUserInfo method of LotusScript NotesRegistration class
Examples: @Domain
1. This example returns WorkSavers if the current user belongs to the WorkSavers domain.
@Domain
2. This formula replaces any occurrences of the users mail address with a null string, thus removing the
current users name from CopyTo.
FIELD CopyTo:=@Replace(CopyTo;@UserName+"@"+@Domain;"");
Note: The above example works only with nonhierarchical names (those IDs certified by a
nonhierarchical certifier).
@DoWhile
Executes one or more statements iteratively while a condition remains true. Checks the condition after
executing the statements.
Syntax
@DoWhile( statement ; ... ; condition )
Parameters
statement
A formula language statement. The maximum number of statements you can include is 254.
condition
Return value
true
True (1) unless an error occurs during execution of the condition. An unexpected data type error occurs
if the conditional expression results in a non-numeric value.
Tip: If you are looping through a field containing a list, be sure the Allow multiple values check box is
selected in the Field Properties box for the list field.
Language cross-reference
Do statement of LotusScript language
Examples: @DoWhile
This agent displays the elements of the Categories field one at a time.
@If(@Elements(Categories) = 0; @Return(0); "");
n := 1;
@DoWhile(
@Prompt([OK]; "Category " + @Text(n); Categories[n]);
n := n + 1;
n <= @Elements(Categories)
)
@EditECL
Displays the administration Workstation Security: Execution Control List dialog box for a specified
address book and name, which lets you change that administration ECL. Administrators can name
Administration ECLs. The name is not usually a user name, but whatever name the administrator
chooses; for example, Manager, Developer, or LimitedAccess.
Syntax
@EditECL( server : database ; name )
Parameters
server : database
Text list. The server location and file name of the address book. Omit server or specify it as (null) for
the local Notes/Domino directory.
name
Text. The name of the ECL. Specify (null) for the unnamed ECL.
Usage
You cannot use this function in Web applications.
Language cross-reference
See LotusScript NotesRegistration class
@EditUserECL
Displays the Workstation Security: Execution Control List dialog box, which allows you to change your
personal ECL for the current workstation.
Syntax
@EditUserECL
Usage
You cannot use this function in Web applications.
Language cross-reference
See LotusScript NotesRegistration class
@Elements
Calculates the number of text, number, or timedate values in a list. This function always returns a
number to indicate the number of entries in the list.
Syntax
@Elements( list )
Parameters
list
Return value
numElements
Number. The number of elements in the list. If the field value is a null string, @Elements(list) returns the
number 0. @Count returns 1 if the field value is a null string or not a list value.
Usage
You can use @Elements in the condition statement of @For functions to set the loop count equal to the
number of elements in the list:
Examples: @Elements
1. This example returns 4 if the list in the SalesForce field is Rogers:Binney:Harris:Larson.
@Elements(SalesForce)
2. This example returns 2.
@EnableAlarms
Starts or stops the alarm daemon.
Syntax
@EnableAlarms( enableAlarms )
enableAlarms
Usage
@EnableAlarms brings up the alarm daemon and sets the $EnableAlarms notes.ini variable. Once the
variable is set, re-entering Lotus Notes/Domino brings up the alarm daemon. The 0 option stops the
alarm daemon if it is running.
Language cross-reference
EnableAlarms method of LotusScript NotesUIWorkspace class
@Ends
Determines if a substring is at the end of a string. @Ends is case-sensitive.
Syntax
@Ends( string ; substring )
Parameters
string
substring
Boolean
v 1 (True) indicates that the substring is at the end of string
v 0 (False) indicates that the substring is not at the end of string
Examples: @Ends
1. This example returns 1.
@Ends("Hi There";"re")
2. This example returns 0.
@Ends("Hi There";"The")
3. This formula checks to see if the end of the Signature field contains the strings Owens or Irons or
Baker. If it does, the string Verify Signature is returned; otherwise, the string Dont Verify Signature
is returned.
@If(@Ends(Signature;"Owens":"Irons":"Baker");"Verify signature"; "Dont Verify Signature")
ENVIRONMENT
A reserved word that sets or gets an environment variable stored in the users notes.ini file (Windows,
OS/2, and UNIX) or Notes Preferences file (Macintosh).
Syntax
ENVIRONMENT variable := textValue ;
Usage
For information on how to use environment variables, see Getting and setting environment variables.
To get the value of an environment variable, use @Environment. To set the value of an environment
variable, you can also use @Environment, or you can use @SetEnvironment.
For Web applications, use predefined field names to gather information about the Web users
environment by requesting Common Gateway Interface (CGI) environment variables.
Language cross-reference
Environ function of LotusScript language
@Environment
Sets or returns an environment variable stored in a formula.
Parameters
variable
Text or text list. The name of the environment variable you want to retrieve. To retrieve multiple
environment variables, use a text list.
value
Text. Optional. The value you want to assign to the environment variable. Since users have their own
notes.ini or Notes Preferences file, this value can be customized for each user. Omit this parameter if you
just want to retrieve the value, not set it.
v If variable is a text list, every environment variable in the list will be assigned value.
v If value is a text list, only the first value in the list is used; the rest are ignored.
Return value
environmentVariable
Text. The value of the environment variable you specified. To use the return value in arithmetic
operations, use @TextToNumber to convert it to a number.
Usage
For information on how to use environment variables, see Getting and setting environment variables in
Formula Language Coding Guidelines.
Use @Environment when you want to set an environment variable within a formula. If its to be nested
within another @function (such as @If or @Do), use @SetEnvironment instead.
@Environment cannot be used in column or selection formulas; its only intended for use in field
formulas, toolbar buttons, and agents. Some formulas, such as scheduled agents, are run on the server
instead of on the users workstation. In this case, the environment variables affected are the server
environment variables, not the workstation variables. You can use a computed text formula to retrieve
variables, but not to set variables.
You can also use @Environment to get the value of an environment variable stored the users notes.ini file
(Windows, OS/2, and UNIX) or Notes Preferences file (Macintosh). You can only set and retrieve the
values of variables that begin with a dollar sign ($) symbol. Do not include the dollar sign in the variable
parameter. For instance, to change the value of the $EnableAlarms INI variable from 1 to 0, enter:
@Environment("EnableAlarms";"0")
For Web applications, use predefined field names to gather information about the Web users
environment by requesting Common Gateway Interface (CGI) environment variables.
Language cross-reference
Environ function of LotusScript language
@Error
Allows you to generate an error condition within an expression. This is useful if you want to evaluate the
current values in several fields and need to know if an error has occurred in the entry of any of them.
Syntax
@Error
Return value
@Error
Usage
Use @IsError to test for a data entry error.
When an error has occurred, @Error is returned. The function cannot return any other value.
@Error always results in an error condition when it tests a single value. If you use @Error alone as a
formula, you will always generate an error.
You cannot test for an @Error value with any operator or @function other than @IsError. If you use an
error value as an argument to an operator or @function, the return is always@Error.
Language cross-reference
On Error statement of LotusScript language
Examples: @Error
Read the following examples closely to understand the difference between @Error and @IsError.
1. This example returns the value in the Price field if it is greater than 100, otherwise it returns @Error.
@If(Price>100;Price;@Error)
@Eval
At run-time, compiles and runs each element in a text expression as a formula. Returns the result of the
last formula expression in the list or an error if an error is generated by any of the formula expressions in
the list.
Syntax
@Eval( textExpressions )
Parameters
textExpressions
Any text expressions that you want @Eval to evaluate. Surround the text expression to be evaluated with
quotation marks ( ) and escape the quotes around individual text expressions within the formula with
back-slashes (\). Use the plus sign (+) to concatenate text expressions.
Return value
lastExpression
Usage
This function is useful in agents, hotspot buttons, and toolbar buttons and when you want to evaluate
multiple text expressions at run-time from within a single @function.
Use of @Eval in view columns and selection formulas may produce unexpected results. Because this
function is evaluated at run-time, the view engine is unable to follow its standard procedure of analyzing
the formulas ahead of time to discover what types of @functions it will encounter and prepare for them.
Language cross-reference
Examples: @Eval
1. This formula concatenates the value of the temporary variable x and the text expression bar. It
returns foobar.
x := "foo";
@Eval("x + \"bar\"");
2. The following code, when added to an action button, creates the field comment and adds the users
input to it on the fly.
input := {FIELD comment := @Prompt([OKCANCELEDIT];"Input";"Input a value"; "Default");};
@Eval(input);
To view the content of the comment field, use the following code in a hotspot or action button.
@Prompt([OK];"Value of comment field";@GetField("comment"))
Syntax
@Exp( power )
Parameters
power
Number. The power to which you want to raise e. Lotus Notes/Domino can only calculate this function
when the number is between 11355.1371 and 11356.5234. Values outside this range will return the value
@ERROR.
Usage
Natural logs use the constant e as their base. Use @Exp in formulas requiring exponential functions.
Language cross-reference
Exp function of LotusScript language
Examples: @Exp
1. This example returns 3.49034295746184 (e raised to the power of 1.25).
@Exp(1.25)
2. This example returns 0.28650479686019 (e raised to the power of 1.25).
@Exp(1.25)
@Explode
Returns a text list composed of the elements of a text string or date range.
v If you specify a text string, elements are defined as sequences of characters separated by separator
characters and newlines.
v If you specify a time-date range, elements are defined as individual days within the range.
Syntax
@Explode( dateRange ) @Explode( string ) @Explode( string ; separators ) @Explode( string ; separators ;
includeEmpties ) @Explode( string ; separators ; includeEmpties ; newlineAsSeparator )
Parameters
dateRange
Time-date range or time-date range list. The range of dates that you want to make into a text list. Specify
a valid date-time range, not a string representation of one. For example, @Explode( 05/01/96 -
05/02/96 ) is invalid because the parameter is a string. Use @Explode( [05/01/96 - 05/02/96] ).
string
Text. The string that you want to make into a text list.
separators
includeEmpties
Boolean. Optional. Specify True (1) to place an empty string () in the returned list when a
separatorappears at the beginning or end of the string, or two separators appear consecutively in the
string.Specify False (0) to not include empty list elements for leading, trailing, and consecutive separators.
Defaults to False.
newlineAsSeparator
Boolean. Optional. Specify True (1) to treat the newline as a separator. Specify False (0) to not treat the
newline as a separator. Defaults to True.
Return value
explodedString
Text list. A list containing each element found in string, or each date found in dateRange.
Language cross-reference
Split function of LotusScript language
Examples: @Explode
Given a semicolon (;) as the default display separator:
1. This example returns a list containing Weekly, Status, and Report if the content of the Topic
field is Weekly Status Report; Weekly,Status,Report; Weekly;Status;Report; or Weekly, Status,
and Report separated by newlines.
@Explode(Topic)
2. This example returns a list containing Weekly, Status, and Report if the content of the Topic
field is Weekly+Status+Report; or Weekly, Status, and Report separated by newlines.
@Explode(Topic; "+&")
3. This example specifies the default separators but inserts empty elements for leading, trailing, and
consecutive separators.
@Explode(Topic; " ,;"; @True)
4. This example specifies the defaults for parameters 2 and 3, but does not treat newlines as separators.
@Explode(Topic; " ,;"; @False, @False)
5. This example returns Please send resume + references if the content of the entry field is: Please
send resume & references.
@Implode( @Explode( entry; "&" ); "+" )
6. This example returns Attendance grows at UCLA; Pomona Colleges; and USC if the content of the
Headline field is Attendance grows at UCLA, Pomona Colleges, and USC.
@Explode(Headline;",")
7. This example returns 4 if the content of the Country field is Mexico, Guatemala, Costa Rica, El
Salvador.
@Failure
Returns a message that you supply; when used in an input validation formula, @Failure displays its
message whenever the entered value does not meet the validation criteria.
Syntax
@Failure( string )
Parameters
string
Return value
string
Usage
@Failure is mainly used in input validation formulas for editable fields, although you can also use it in
agents and form formulas. When @Failure is used in formulas other than input validation formulas, the
result is the input string; Lotus Notes/Domino displays no prompts or messages.
Language cross-reference
On Error statement of LotusScript language
Examples: @Failure
This example show an input validation formula. It returns the error message Area codes have only 3
digits if the user enters a number greater than 999 in the field named AreaCode.
@If(AreaCode<1000;@Success;@Failure("Area codes have only 3 digits"))
@False
Returns the number 0.
Return value
Returns the number 0.
Usage
This function is equivalent to @No.
Language cross-reference
Built-in constants of LotusScript language
Examples: @False
1. This example returns 0.
@False
2. This example returns 0 if the value in the field named Cost is 100 or less.
@If(Cost>100;@True;@False)
FIELD
A reserved word that is necessary when you are assigning values to fields that are stored in a document
(as opposed to temporary fields). You can use FIELD to change the contents of an existing field or to
create new fields.
You cannot use the FIELD reserved word within an @function. Use @SetField instead.
Syntax
FIELD fieldName := value ;
CAUTION:
When you use FIELD to create a new field in existing documents, make sure that you do not duplicate
the name of a field that already exists.
In some cases, action formulas that dont evaluate to a result (for example, a button formula) return a
No Main or Selection expression in formula error message. You can supply a value such as an empty
string (), or you could provide an expression at the end of the formula, as shown below:
SELECT @All
Usage
This reserved word is most useful in agent, button, hotspot, and action formulas. It does not work in
column, selection, hide-when, window title, or form formulas.
Language cross-reference
ReplaceItemValue method of LotusScript NotesDocument class
@FileDir
Returns the directory portion of a path name, that is, the path name minus the file name.
Syntax
@FileDir( pathname )
Parameters
pathname
Return value
directory
Usage
The directory part of a file name is everything to the left of the file name as demonstrated below:
Use @Right with the path name and @FileDir to extract the file name.
Examples: @FileDir
1. This computed field formula returns the directory part of the file named by Pathname.
@FileDir(Pathname)
2. This computed field formula returns the file name part of the file named by Pathname.
@Right(Pathname; @FileDir(Pathname))
@FloatEq
Compares two numbers for equality within a confidence range.
Syntax
@FloatEq( number ; number ; confidenceRange )
Parameters
number
confidenceRange
Number. Optional. The amount within which the numbers must be equal. Defaults to 0.0001.
Return value
flag
Boolean.
v Returns 1 (True) if the difference of the numbers is less than the confidence range.
v Returns 0 (False) if the difference of the numbers exceeds or is equal to the confidence range.
Usage
@FloatEq is helpful in dealing with the inexactness of floating point operations.
Examples: @FloatEq
This action formula compares the fields SpecifiedLength and MeasuredLength, and displays a message if
the fields are not within 0.01.
@If(@FloatEq(SpecifiedLength; MeasuredLength; 0.01); "";
@Prompt([OK]; "Length is out of spec";
@Text(MeasuredLength)))
@FontList
Provides a list of available fonts on the Lotus Notes client where this @function is executed.
Syntax
@FontList
Text list. All the available font names. For Default Serif, Default Sans Serif, and Default Monospace
fonts, @FontList returns alias values as follows:
v Default Serif, 0
v Default Sans Serif, 1
v Default Monospace, 4
Usage
Use @FontList as the keyword formula for a list field to display a list of fonts that are available on to the
users.
Examples: @FontList
1. The following formula returns a list of font names such as Arial : Courier : Default Sans Serif|1 :
Default Serif|0 : Default Monospace|4 : Times New Roman.........
@FontList
2. The following code, when added to the Change font hotspot button on a form enables the user to
apply the font they select from the fontList listbox field to the text in the Body rich text field.
@Command([EditGoToField];"Body");
@Command([EditSelectAll]);
@Command([TextSetFontFace];fontList)
To display the fonts available to the user in the fontList field, set the field Type to a list field, by
choosing Listbox or Dialog list, for example. On the control tab of the Field Properties box, select the
Use formula for choices option and enter the following formula:
@FontList
@For
Executes one or more statements iteratively while a condition remains true. Executes an initialization
statement. Checks the condition before executing the statements and executes an increment statement
after executing the statements.
Syntax
@For( initialize ; condition ; increment ; statement ; ... )
Parameters
initialize
condition
increment
A formula language statement. The maximum number of statements you can include is 252.
Return value
true
True (1) unless an error occurs during execution of the condition. An unexpected data type error occurs
if the conditional expression results in a non-numeric value.
Usage
@For executes the initialize statement once. Next @For evaluates the condition. If the condition is True (1),
@For executes the statements, executes the increment statement, and evaluates the condition again. If the
condition is False (0), @For terminates.
Tip: If you are looping through a field containing a list, be sure the Allow multiple values check box is
selected in the Field Properties box for the list field.
The formula engine exits a formula or breaks an infinite loop if the time spent performing the iterations
exceeds the standard timeout value allowed for an operation.
Language cross-reference
While statement of LotusScript language
Examples: @For
1. This agent displays the elements of the Categories field one at a time.
@For(n := 1;
n <= @Elements(Categories);
n := n + 1;
@Prompt([OK]; "Category " + @Text(n); Categories[n]))
2. This computed field formula concatenates the list elements in the fname and lname fields:
@For(n :=1; n<=@Elements(fname); n:= n + 1;
full := @If(n=1;fname[n] + " " + lname[n];full : (fname[n] + " " + lname[n])));
full
If fname contains: Catherine:Patricia:Maureen and lname contains: Rolling:Kearns:Legacy,
the result is: Catherine Rolling;Patricia Kearns;Maureen Legacy. If fname and lname each contain a
different number of elements, be sure to include the field that has fewer elements in the @Elements
function or an Array index out of bounds error results.
3. This computed field formula displays the longest name in a text list of poets names stored in the
poets field. If the poets field contains T.S. Eliot:Dorothy Parker:Edna St. Vincent Millay:e.e.
cummings: this field displays Edna St. Vincent Millay.
temp := "";
@For(n := 1; n <= @Elements(poets); n := n + 1;
@If(@Length(poets[n])>@Length(temp);
temp := poets[n];temp));
temp
Syntax
@FormLanguage
Return value
language
Text. The language specified for the current form. Format of this information is based on RFC1766.
Usage
If the database contains multilingual forms, you can specify the language for each form.
Language cross-reference
Language property of LotusScript NotesName class
Examples: @FormLanguage
The following formula returns en-US when used on a form designed in English(United States).
@FormLanguage
@GetAddressBooks
Returns a list of the address books associated with a client (if the current database is local) or server.
Syntax
@GetAddressBooks( [ options ] )
Parameters
[ options ]
Keyword. You must select one of the following keywords as an argument for this @function:
[TITLES]
Returns the file names of the address books associated with the current database.
[FIRSTONLY]
Displays only the first database in the returned text list of address book names.
Return value
address books
Examples: @GetAddressBooks
1. This code populates the chooseAddress listbox field options with names.nsf and
AcmeNorthServer!!names.nsf when added to the Use formula for choices textbox on the Control tab
of the field properties box if the database containing the chooseAddress field is running on the Acme
server:
@GetAddressBooks([TITLES])
2. This code populates the chooseAddress listbox field options with names.nsf when added to the Use
formula for choices textbox on the Control tab of the field properties box if the database containing
the chooseAddress field is running on the Acme server:
@GetAddressBooks([FIRSTONLY])
@GetCurrentTimeZone
Returns the current operating systems time zone settings in canonical time zone format.
Syntax
@GetCurrentTimeZone
Return value
fieldValue
Canonical time zone representing the time zone settings of the operating system.
Usage
Use with the @TimeZoneToText function to translate the time zone value returned into a readable time
zone value.
Examples: @GetCurrentTimeZone
1. This code, when added as the default value for a field, returns Z=5$DO=1$DL=4 1 1 10 -
1$ZX=10$ZN=Eastern if the current operating systems time zone setting is GMT-05:00 Eastern Time.
@GetCurrentTimeZone
2. This code, when added as the default value for a field, returns (GMT-5:00) Eastern Time (US &
Canada).
@TimeZoneToText(@GetCurrentTimeZone)
@GetDocField
Given the unique ID of a document, returns the contents of a specific field on that document. The
document must reside in the current database.
Syntax
@GetDocField( documentUNID ; fieldName )
Parameters
documentUNID
fieldName
Text. The name of a field on the document, enclosed in quotation marks. If you store the field name in a
variable, omit the quotation marks here.
Return value
fieldValue
Text or text list; number or number list; time-date or time-date range. The contents of the field on the
specified document. Returns null if the UNID or field name is invalid.
Usage
This function does not work in column or selection formulas.
Language cross-reference
FieldGetText method of LotusScript NotesUIDocument class
Examples: @GetDocField
1. You have a discussion database with main topics and responses. In each response, you want to store
the subject of the parent document in a field called OriginalSubject. You want OriginalSubject to
change if the subject of the main topic changes, so you write this formula for it. $Ref is a special field
on a response document that contains the unique ID of the parent document.
@If(@IsNewDoc; Subject; @GetDocField($Ref; "Subject"))
2. The following formula can run a scheduled agent to update the contents of a child document, based
on the parent.
FIELD Project:=@GetDocField($Ref; "Project");
@All
3. The following formula runs a scheduled agent to update the contents of one document based on the
content of another. The documents dont need to be parent and child. For example, these could be
two parent documents or two child documents.
FIELD Body:=@GetDocField("BB791838F30B20ED852567BA0064DDAF"; "Body");
@All
@GetField
Returns the value of a specified field.
Syntax
@GetField ( fieldName )
Return value
value
Usage
This @function returns null if the field does not exist.
This @function is useful in writing portable code and in other instances where you want to vary the
name of the field.
If the field specified in fieldName is marked to Allow multiple values, this function returns the first value
only.
Language cross-reference
FieldGetText method of LotusScript NotesUIDocument class
Examples: @GetField
1. This code, when added to a computed field on a form and accessed on the Web or in Notes, displays
Hello if Hello is the default value of the greeting field.
@GetField("greeting")
2. This computed field formula multiplies values from two fields. The fields are named by adding
suffixes to the name of the current field.
@GetField(@ThisName + "_Quantity") * @GetField(@ThisName + "_Cost")
@GetFocusTable
Returns the name, current row, or current column of the table that is in focus.
Syntax
@GetFocusTable ( [ tableInfoRequest ] )
Parameters
[ tableInfoRequest ]
[CELLROW]
Returns the current row number starting at 1; returns 0 if a table is not in focus.
Returns the current column number starting at 1; returns 0 if a table is not in focus.
[TABLENAME]
Returns the table name (Name/Id under the Table Programming tab in Table Properties); returns a null
string if a table is not in focus or the table has no name.
Return value
tableInfo
Usage
This @function works in the OnHelp event of a form. It is triggered by selecting Help - Context Help
from the menu bar or pressing F1 when:
v The cursor is in a field in a table cell when the document is in edit mode
v Text or an object is selected in a table cell and the document is in read mode
When focus is in the tab of a tabbed table, [CELLCOLUMN] always returns zero.
Examples: @GetFocusTable
This onHelp event returns the name, row, and column of a table that is currently in focus.
row := @GetFocusTable([CELLROW]);
@If(row = "0"; @Prompt([OK]; "*No table*"; "Not in a table");
@Do(
column := @GetFocusTable([CELLCOLUMN]);
name0 := @GetFocusTable([TABLENAME]);
name := @If(name0 = ""; "No name"; name0);
@Prompt([OK]; "*" + name + "*";
"Row " + row + ", column " + column)))
@GetHTTPHeader
In a Web application, returns the value of an HTTP header from the browser client request being
processed by the server.
Syntax
@GetHTTPHeader( requestHeader )
Parameters
requestHeaderField
Text. The name of a request-header field, for example, From, Host, or User-Agent.
Text. The value of the request-header field, or null if the field does not exist.
Usage
@GetHTTPHeader is useful in formulas that run in the context of a browser.
Language cross-reference
Table of CGI variables
Examples: @GetHTTPHeader
The examples below return header field content based on this standard HTTP request:
GET /yourdb.nsf/All?OpenView HTTP/1.0
User-Agent: Mozilla 4.0 (X; I; Linux-2.0.35i586)
Host: mylinuxbox.ibm.com
Accept: image/gif, image/jpeg, */*
1. This computed field formula returns Mozilla 4.0 (X; I; Linux-2.0.35i586.
@GetHTTPHeader("User-Agent")
2. This computed field formula returns mylinuxbox.ibm.com.
@GetHTTPHeader("Host")
@GetIMContactListGroupNames
Returns the group names in the Instant Messaging Contact List.
Syntax
@GetIMContactListGroupNames
Return value
nameList
Text list. All group names in the Instant Messaging Contact List.
@GetPortsList
Returns a list of enabled or disabled ports.
Syntax
@GetPortsList( [ portType ] )
Parameters
[ portType ]
[ENABLED]
[DISABLED]
Return value
portsList
Usage
@GetPortsList is used by the Public and Personal Address books to determine the list of available ports
for each Location record. You can then select a port from that list.
This function does not work in column formulas, selection formulas, or selective replication formulas.
Examples: @GetPortsList
1. This example returns Lan0;TCP;AppleTalk if those are the currently enabled ports.
@GetPortsList([Enabled])
2. This example returns COM1;COM2 if those are the currently disabled ports.
@GetPortsList([Disabled])
Note: The text list uses the multi-value separator specified for the current field, or the list separator
specified for the current column in a view.
@GetProfileField
Retrieves a field from a profile document, and caches the field value for the remainder of the session.
Syntax
@GetProfileField( profilename ; fieldname ; uniqueKey )
Text. The name of the profile document that contains the field you want to access.
fieldname
uniqueKey
Return value
fieldvalue
Usage
This function does not work in column, hide-when, section editor, or view selection formulas. You can
use it in toolbar buttons or agents.
You can use this function on the Web. Use @SetProfileField to create a profile document in a Web
application. If no profile document by the name specified as the first parameter to @SetProfileField exists,
Notes creates one. This function enables you to access the fields in that profile document.
Language cross-reference
FieldGetText method of LotusScript NotesUIDocument class
Examples: @GetProfileField
1. This example gets the contents of the ProfileCategories field of the Interest Profile document.
@GetProfileField("Interest Profile";
"ProfileCategories")
2. This example gets the contents of the ProfileCategories field of the Interest Profile document for
the profile document for Monday if weekday has Monday as its default value.
@GetProfileField("Interest Profile";
"ProfileCategories"; "weekday")
3. This example gets two field values from the age and job fields of the userprofile profile document
and displays them vertically in a view column. The following code is in the profile field of a
user-accessible form:
@Explode(@GetProfileField("userprofile"; "age"; @UserName):@GetProfileField("userprofile"; "job"; @UserName); ":")
The column formula of the view that displays these two values has its view properties set to Lines
per row = 2 and Shrink rows to content and column properties set to Multi-value separator = New
Line. The column value formula is the following:
@Trim(profile)
The @Explode function replaces the semicolon (;) that returns to the profile field with the colon (:)
which indicates to the @Trim function in the column formula that the two values are a text list.
@GetViewInfo
Returns a view attribute.
Syntax
@GetViewInfo ( [ attribute ] ; column )
Parameters
[ attribute ]
[CalendarViewFormat]
Returns as a numeric value the number of days displayed: 1, 2, 5, 7, and so on. Applies to calendar views
only.
[ColumnValue]
Returns as a text value the value of a column for the current row. Requires the second parameter.
[IsCalViewTimeSlotOn]
Returns @True if time slots are displayed on the lefthand side, @False otherwise. Applies to 1-day and
2-day calendar views only.
column
Number. Required for [ColumnValue]; otherwise does not apply. The column number starting with 0 for
the first column and counting hidden columns.
Return value
value
Usage
This function is not available in selection or column formulas and will return null if used there.
Look at the view design or design synopsis to determine column numbers. You cannot count columns by
looking at a view in the Notes client or a browser.
v If you look at the view in Domino Designer, the first column is 0, the second column is 1, and so on.
Examples: @GetViewInfo
1. This hide-column formula hides the End date column in a calendar view if time slots are enabled or
the format is for 30 days.
@GetViewInfo([IsCalViewTimeSlotOn]) = @True |
@GetViewInfo([CalendarViewFormat]) = 30
2. This hide-action formula hides an action if column 4 (a hidden column) has the programmatically
assigned value Task.
@GetViewInfo([ColumnValue]; 4) = "Task"
3. This default field value on a form displays the value of the third column in the view used with that
form.
@GetViewInfo([ColumnValue];2)
@HardDeleteDocument
In an agent that runs a formula, @HardDeleteDocument permanently removes the document currently
being processed from the database if the database has soft deletions enabled. If the database does not
have soft deletions enabled, @HardDeleteDocument performs the same action as @DeleteDocument.
Syntax
@HardDeleteDocument
Usage
This function is intended only for use in agents that run formulas; it has no effect when run elsewhere.
To mark a document for deletion from an icon, view, or form action, use @Command[EditClear].
To create an agent that deletes documents from a database without using a formula, use the Simple
action Delete from Database.
Language cross-reference
Delete Document URL command
@HashPassword
Encodes a string.
Parameters
string
Return value
encodedString
Text. The passed-in string, double digest encoded for maximum security.
Usage
Some person records contain a $SecurePassword hidden field, which is double digest encoded in the
@HashPassword format. If this field is not present in the record, the digest is encoded in the @Password
format. @HashPassword creates a more secure password than the @Password function does.
@Hour
Returns the number of the hour in the specified timedate.
Syntax
@Hour( timeDateValue )
Parameters
timeDateValue
Time-date. The value with the hour that you want to extract.
Return value
hour
Number. A number representing the hour contained in timeDateValue. Hours are represented as 0 through
23 for 12 AM through 11 PM. Returns -1 if the time-date provided contains only a date and not a time
value.
Language cross-reference
Hour function of LotusScript language
Examples: @Hour
1. This example returns 9.
@Hour([9:30])
2. This example returns 8 if the time in the Date field is 8:56:34 AM.
@Hour(Date)
3. This example returns 20 if a Date field is made up of the date and time: 7/30/90 8:56:34 PM.
@Hour(Date)
4. This example returns 3 if the current document was created on 2/15/92 at 3:00:12 A.M.
@Hour(@Created)
Syntax
@If( condition1 ; action1 ; condition2 ; action2 ; ... ; condition99 ; action99 ; else_action )
Parameters
condition
Expression that returns a Boolean. If this expression returns True, action is performed. If its False, Lotus
Notes/Domino skips to the next condition, if there is one. Otherwise, Lotus Notes/Domino performs
else_action.
action
else_action
Usage
In its simplest form, the If statement looks like this: @If( condition ; action ; else_action ).
You can list up to 99 conditions and corresponding actions, followed by just one action to be performed
when all the conditions are False. As soon as a condition evaluates to True, Lotus Notes/Domino
performs the associated action and ignores the remainder of the @If statement.
Lotus Notes/Domino accepts the form @If( condition ), with only one condition and no action, but does
not perform any action based on the condition.
If you compare a field to a value (for example, Year > 1995) and the field is unavailable, the comparison
is False. However, you should check for fields that may not be present with @IsUnavailable.
Language cross-reference
If...Then...Else statement of LotusScript language
Examples: @If
1. This formula tests the single value in the CostOfGoods field. If the value is greater than or equal to
12.45, the condition is True, and the string Over Budget is returned. If the value is less than 12.45,
the condition is False and the string Bill of Materials OK is returned.
@If(CostOfGoods>=12.45;"Over Budget";"Bill of Materials OK")
2. In this example, if CostOfGoods is less than 12.45, the null string is returned.
@If(CostOfGoods>=12.45;"Over Budget";"")
@IfError
Returns a null string () or the value of an alternative statement if a statement returns an error.
Syntax
@IfError( statement1 ; statement2 )
Parameters
statement1
statement2
Optional. A formula statement. This statement, if available, executes if the first statement returns an error.
Return value
statementReturn
v Returns the value of the first statement if it is not an error.
v Returns the value of the second statement if the value of the first statement is an error and the second
statement is supplied.
v Returns a null string () if the value of the first statement is an error and the second statement is
omitted.
Language cross-reference
On Error statement of LotusScript language
Examples: @IfError
1. This agent tests the return value of an @DbLookup statement for an error. If the @DbLookup
statement causes an error, the agent returns the text Not available.
FIELD Phone :=
@IfError(
@DbLookup(""; "Snapper" : "names.nsf"; "People";
@Right(Name; " ") + " , " + @Left(Name; " "); "OfficePhoneNumber");
"Not available")
This agent does the same thing, using @If instead of @IfError.
result := @DbLookup("";"Snapper":"names.nsf";"People";
@Right(Name;" ") + " , " + @Left(Name; " "); "OfficePhoneNumber");
FIELD Phone := @If(@IsError(result);"Not available";result)
2. The following code, when added to a Computed for display field, displays the price of the product
entered in the product field, after a page refresh. Enter the text, Enter product name here as the
default value for the product field. Once a user enters a product name in the product field and
presses F9, the price is extracted from the Goods view, which contains the product name in the first
sorted column and its price in the second column. If the product name is not recognized or any other
error occurs during the lookup, the message, Unable to retrieve requested price. Aborting lookup
displays. You could add a Get Price action button that contains the code:
@Command([ViewRefreshFields]) to prompt the user to refresh the page.
@If(product="Enter product name here";0;@IfError(@DbLookup("" : "" ;
"product/server" : "filename\\productdatabase.nsf" ; "Goods" ; product ;
2); "Unable to retrieve requested price. Aborting lookup"))
3. This formula, when added to the Apply font hotspot button, applies the font a user selects from the
fonts Dialog list field to the text the user enters or highlights in the Body Rich Text field. The
fonts field contains an @FontList function in the Use formula for choices box in its Field Properties
box, which displays a list of available fonts. If no font was selected from the fonts field, an error
message displays which instructs the user to select one.
@Command([EditGoToField]);"Body");
@Command([EditSelectAll]);
@IfError(@Command([TextSetFontFace];fonts);@Prompt([Ok];"Error encountered";"You must select a font first"))
@Implode
Concatenates all members of a text list and returns a text string.
Syntax
@Implode( textlistValue ) or @Implode( textlistValue ; separator )
Parameters
textlistValue
separator
Text. Used to separate the values in the concatenated string. If you dont specify a separator, a space is
used.
Return value
implodedString
Language cross-reference
Join function of LotusScript language
Examples: @Implode
1. This example returns Minneapolis Detroit Chicago if the contents of the City field are
Minneapolis:Detroit:Chicago.
@Implode(City)
2. This example returns Minneapolis,Detroit,Chicago if the contents of the City field are
Minneapolis:Detroit:Chicago.
@Implode(City;",")
3. This example returns European Capitals/Bonn : European Capitals/Lisbon : European
Capitals/Madrid if the contents of the Categories field are European Capitals, and the content of the
Cities field is a list consisting of Bonn, Lisbon, and Madrid.
@Implode(Categories + "/" + City ; " : ")
@InheritedDocumentUniqueID
The unique ID of the current documents inheritance parent. See @DocumentUniqueID for a description
of unique IDs.
Syntax
@InheritedDocumentUniqueID
Usage
This function works in a document being created with a form with field values inherited from the
selected document.
Language cross-reference
ParentDocumentUNID property of LotusScript NotesDocument class
@Integer
Truncates the values in a number or number list at the whole number, leaving off any decimals. The
values in the resulting list are separated using the multivalue separator that is selected for display in the
field containing the formula.
Syntax
@Integer( numberValue )
Parameters
numberValue
Return value
truncatedValue
Usage
When using this function with a number list, the list concatenation operator takes precedence over any
other operators. Negative numbers must be enclosed in parentheses.
Language cross-reference
CInt function of LotusScript language
@IsAgentEnabled
Indicates whether or not a scheduled agent is enabled.
Syntax
@IsAgentEnabled( agent )
Parameters
agent
Return value
flag
Number
v 1 (True) indicates that the agent is enabled
v 0 (False) indicates that the agent is disabled, or that an agent by that name does not exist
Usage
A database must be open. If a database is not open, returns 0.
@IsAgentEnabled returns 1 for macros created in Lotus Notes Release 3, and for any agents that are not
scheduled.
@IsAgentEnabled does not work in column or selection formulas and is not intended for use in window
title or form formulas.
Language cross-reference
IsEnabled property of LotusScript NotesAgent class
Examples: @IsAgentEnabled
This example returns 1 if the UnderCover agent is enabled; otherwise, it returns 0.
@IsAgentEnabled( "UnderCover" )
Syntax
@IsAppInstalled( application )
Parameters
application
Text. Specify Designer to check if the Domino Designer is installed on the system, or Admin to check
if the Domino Administrator is installed.
Return value
flag
Boolean
v True indicates that the specified application is installed
v False indicates that the specified application is not installed
Usage
This @function is generally used in hide-when formulas.
@IsAvailable
Checks a document for the existence of a field.
Syntax
@IsAvailable( fieldName )
Parameters
fieldName
Field. The name of a field. Do not treat the name as text. Enter the exact name of the field and do not
enclose it in quotes.
Return value
flag
Boolean
v 1 (True) indicates that the field is contained in the document
v 0 (False) indicates that the field is not contained in the document
Usage
Use @IsAvailable to provide a default value for documents created with forms that do not include a field
name.
This function can be used with select and column formulas using Summary fields only. Non-Summary
fields are not available.
Language cross-reference
HasItem method of LotusScript NotesDocument class
Examples: @IsAvailable
1. This formula returns the value of the Dept field if it exists in the document, otherwise it returns
Consultant.
@If(@IsAvailable(Dept);Dept;"Consultant")
2. This formula returns the value of the field named Topic if it exists in the document, otherwise it
returns the value contained in the field named Subject.
@If(@IsAvailable(Topic);Topic;Subject)
3. This formula, when added to a hotspot button, checks for the existence of the Priority field in a form,
then sets its value if found or creates a new Priority field and sets its value, if not found.
@If(@IsAvailable(Priority);@SetField("Priority";"High");FIELD Priority := "High")
Note: If you create the field using this formula, it is not visible on the form, but you can get its value
using the @GetField function. Be sure you use the correct spelling and capitalization when checking
for the field in the document.
@IsCategory
In a column formula, returns a specified string if any item in the row of a view is defined as a category.
Syntax
@IsCategory @IsCategory( trueString ) @IsCategory( trueString ; falseString )
Parameters
trueString
falseString
Return value
specifiedString
Text.
No parameters:
v * (asterisk) indicates that the entry is a category
v If the entry is a document, returns nothing
Usage
Use @IsCategory only in column formulas.
This function only looks at the columns to its right, so be sure to place it to the left of the categorized
column to which you are referring.
This function does not work in Web applications running version 4.5.
Examples: @IsCategory
1. This example returns * if the row is a category, or nothing if the row is not a category.
@IsCategory
2. This example returns C if the row is a category, or nothing if the row is not a category.
@IsCategory("C")
3. This example returns Y if the row is a category, or N if the row is not a category.
@IsCategory("Y";"N")
@IsDB2
Given a server and filename or server and replica ID, indicates if the specified database is backed by DB2
or not.
Syntax
@IsDB2(server : file)
@IsDB2(server ; replicaID)
Parameters
server
Text. The name of the server. Use an empty string () to indicate the local computer.
file
Text. The path and file name of the database. Specify the database path and file name using the
appropriate format for the operating system.
replicaID
Return value
flag
Boolean
v 1 (True) indicates that the specified database is backed by DB2
v 0 (False) indicates that the specified database is not backed by DB2
Usage
This function works in all contexts where @function use is supported, including view selection formulas,
column formulas, and from the Web.
If the database has been replicated to a local replica, and an empty string is specified for the server
parameter, @IsDB2 will produce an error on the replica. For this reason, it is extremely important to use
@Error processing with @IsDB2 when using relative paths.
Examples: @IsDB2
1. This formula returns 0 (False), since the local names.nsf database is not in DB2:
@IsDB2("":names)
2. These formulas both return DB2 information about the current database:
@IsDB2(@DbName)
@IsDB2("":"")
3. This formula returns 1 if FRITES.NSF in the MAIL directory on the server Belgium is DB2 backed.
Otherwise it returns 0.
@IsDB2( "Belgium" : "mail\\frites.nsf" )
4. This formula returns DB2 information about a database using its replica ID instead of its file name:
@IsDB2("Cheshire";"852556DO:00576146")
5. This example of a column formula first uses @IsDB2 to find out if the local database referenced in the
dbname field of the document is a DB2 database, so that a more meaningful error message may be
displayed from @DB2Schema:
result1 := @IsDB2("":dbname);
result2 := @DB2Schema("":dbname)
@If(@IsError(result1);"Unable to find database or lost server connection";
result1;@If(@IsError(result2);
"Unable to find database or lost server connection";result2);
"Not a DB2 database");
@IsDocBeingEdited
Checks the current status of the document and returns 1 (True) if the document is being edited; otherwise
returns 0 (False).
Syntax
@IsDocBeingEdited
Return value
flag
Boolean
v 1 (True) indicates that the document is being edited
v 0 (False) indicates that the document is not being edited
Usage
This function does not work in column, selection, agent, form, or view action formulas. Its intended for
use in button, hide-when, field, and form action formulas.
Examples: @IsDocBeingEdited
This code, when added to an action button, checks whether the current document is in edit mode. If its
not, it changes the documents mode to edit in order to execute the @DocLock function, which requires
that the current document be in edit mode. It then locks the current document.
@If(@IsDocBeingEdited; @True;@Command( [EditDocument] ; 1 ));
@DocLock([Lock])
@IsDocBeingLoaded
Checks the current status of the document and returns 1 (True) if the document is being loaded into
memory for display; otherwise returns 0 (False).
Syntax
@IsDocBeingLoaded
Return value
flag
Boolean
v 1 (True) indicates that the document is actually being loaded into memory
v 0 (False) indicates that the document is not being loaded into memory
Usage
Use function in field and form formulas. It does not work in toolbar button, selection, column, agent,
section editor, hotspot, form action, or view action formulas.
Examples: @IsDocBeingLoaded
1. This example returns 1 when the document is being loaded into memory.
@IsDocBeingLoaded
2. This example returns 0 when the document is saved.
@IsDocBeingLoaded
3. This example, when used in a computed field named Editors, displays the contents of $UpdatedBy
when the document is being loaded. When the user recalculates the field (by pressing F9), the field
displays the users name as the current editor, followed by previous editors names. When the
document is saved, the value of Editors remains unchanged.
@If(@IsDocBeingLoaded;$UpdatedBy;
@IsDocBeingRecalculated;("Current Editor - " + @UserName):$UpdatedBy;Editors)
@IsDocBeingMailed
Checks the current status of the document and returns 1 (True) if the document is being mailed;
otherwise, returns 0 (False).
Syntax
@IsDocBeingMailed
Boolean
v 1 (True) indicates that the document is actually being mailed
v 0 (False) indicates that the document is not being mailed
Usage
Use @IsDocBeingMailed in field formulas. This function is useful for calculating the number of times the
user has mailed a document, including the number of times the document has been forwarded. It is also
useful for changing a document during mailing; for example, you can change a documents form when it
is mailed.
It has limited usefulness in toolbar button, hotspot, and form action formulas. This function does not
work in column, selection, agent, window title, form, or view action formulas.
Examples: @IsDocBeingMailed
1. This example returns 1 when the document is being mailed.
@IsDocBeingMailed
2. This example returns 0 before and after the document has been mailed.
@IsDocBeingMailed
3. This formula is used in a field to calculate the number of times a document has been mailed. When
this formula is provided as the definition of a computed field called TimesMailed, the field is
initialized to 0 (since the document has not been mailed). TimesMailed is incremented with every mail
operation, so if the document has been mailed once, the contents become 1, and the count increases
by one each time the document is mailed.
@If(@IsUnavailable(TimesMailed);0;
TimesMailed+@IsDocBeingMailed)
@IsDocBeingRecalculated
Checks the current status of the document and returns 1 (True) if the document is being recalculated;
otherwise, returns 0 (False).
Syntax
@IsDocBeingRecalculated
Return value
flag
Boolean
v Returns 1 (True) only when the fields on the document are actually being recalculated
v Returns 0 (False) when the fields on the document are not currently being recalculated
Usage
Use @IsDocBeingRecalculated in field formulas. It has limited usefulness in toolbar button, hotspot, and
form action formulas. This function does not work in column, selection, agent, window title, form, or
view action formulas.
Examples: @IsDocBeingRecalculated
1. This example returns 1 while the document is being calculated or recalculated.
@IsDocBeingRecalculated
2. This example returns 0 before and after the document is calculated or recalculated.
@IsDocBeingRecalculated
3. This example can be used in a timedate field to display different dates under different circumstances.
The formula causes the current timedate to be displayed if the document is recalculated during the
editing process; otherwise, it displays the original creation date of the document.
@If(@IsDocBeingRecalculated;@Now;@Created)
@IsDocBeingSaved
Checks the current status of the document and returns 1 (True) if the document is being saved; otherwise,
returns 0 (False).
Syntax
@IsDocBeingSaved
Return value
flag
Boolean
v Returns 1 (True) only when the fields on the document are actually being saved
v Returns 0 (False) when the fields on the document are not currently being saved
Usage
Use @IsDocBeingSaved in field formulas. It has limited usefulness in toolbar button, hotspot, and form
action formulas. This function does not work in column, selection, agent, window title, form, or view
action formulas.
If you are using this function to increment a counter, the count increases by one every time the user saves
the form.
Examples: @IsDocBeingSaved
1. This example returns 1 while the document is being saved.
@IsDocBeingSaved
2. This example returns 0 before or after the document is saved.
@IsDocBeingSaved
3. This formula sets the field named Readers, which is a Reader Names field, to Admins when the
document is saved. Otherwise, it sets the Readers field to the value already in the field. This type of
formula is useful for changing the Read Access of a document after it has been composed and saved.
@If(@IsDocBeingSaved;"Admins";Readers)
@IsDocTruncated
Indicates whether the current document has been truncated.
Return value
flag
Boolean
v Returns 1 (True) if the document is missing some data
v Returns 0 (False) if the entire document is present
Usage
You typically use @IsDocTruncated in a column formula to display the truncated document indicator. You
can also use @IsDocTruncated in a variety of other formulas, including toolbar buttons, hide-when
formulas, section editors, window title formulas, field formulas, form formulas, column formulas,
selection formulas, and agents.
Documents may be truncated during database replication. Depending upon the type of truncation, a
document can be missing an attached file, an OLE object, large rich text fields, or non-summary items.
If the document is truncated, you can obtain the entire document by choosing Action - Retrieve Entire
Document, either in the background or during the next replication of the database. You cannot edit a
truncated document.
Language cross-reference
Abstract property of LotusScript NotesReplication class
Examples: @IsDocTruncated
This code, when added to a column formula, displays a negative (-) icon if the document was truncated
in replication. The column must be set to Display values as icons in the Column Properties box.
@If(@IsDocTruncated;97;0)
@IsEmbeddedInsideWCT
Indicates whether any part of the current Notes session is embedded inside of Workplace client.
Syntax
@IsEmbeddedInsideWCT
Return value
flag
Boolean
v Returns 1 (True) if any Notes content is open inside Workplace client (even bookmarks)
v Returns 0 (False) if this is a standalone Notes environment, or if in the current session, no Notes
content is open inside Workplace client
Language cross-reference
IsEmbeddedInsideWCT property of the LotusScript NotesUIWorkspace class
Examples: @IsEmbeddedInsideWCT
If the Notes content is being viewed from within Workplace client, you will use Instant Messaging. If not,
you will use Sametime. You create actions to use both, and want to show only the one that is appropriate
for the current environment.
This function, placed in the Hide When tab of the Sametime action, will hide the action when any Notes
content is open within Workplace client.
@IsEmbeddedWithinWCT
This function, placed in the Hide When tab of the Instant Messaging action, will hide the action in a
standalone Notes environment or when no Notes content is open within Workplace client.
@Not(@IsEmbeddedWithinWCT)
@IsError
Returns 1 (True) if the value is an @ERROR value, returns 0 (False) if not an error.
Syntax
@IsError( value )
Parameters
value
Number. Can be a literal value or a field name containing data of type Number.
Return value
flag
Boolean
v Returns 1 (True) if the value is an @ERROR value
v Returns 0 (False) if not an error
Language cross-reference
Err function of LotusScript language
Examples: @IsError
1. This example returns 1.
@IsError(1/0)
@IsExpandable
In column formulas, returns a specified string if a row in a view can be expanded.
Syntax
@IsExpandable @IsExpandable( trueString ) @IsExpandable( trueString ; falseString )
Parameters
trueString
falseString
Return value
specifiedString
Text
No parameters:
v Returns + (plus) if the entry is expandable
v Returns - (minus) if the entry is not expandable
Usage
Use @IsExpandable in column formulas to indicate whether the current level of documents can be
expanded. This function does not work in any other formula.
In the single parameter and two parameter forms, you should limit the string to a single character,
especially if the lines already have a lot of text in them.
@IsMember
Indicates if a piece of text (or a text list) is contained within another text list. The function is
case-sensitive.
Syntax
@IsMember( textValue ; textListValue ) @IsMember( textListValue1 ; textListValue2 )
Parameters
textValue
Text.
textListValue
Text list.
textListValue1
Text list.
textListValue2
Text list.
Return value
flag
Boolean
v Returns 1 (True) if the textValue is contained in textListValue
v Returns 0 (False) if not
v If both parameters are lists, returns 1 if all elements of textListValue1 are contained in textListValue2
Usage
In processing lists, @IsMember differs from a simple = test. An = returns True if the pair-wise comparison
of two entities has even one member; that is, it is not empty.
For more information on pair-wise operations, see the topic Operations on lists in the Formula
Language Rules chapter.
@IsMember returns True only if the first parameter is an exact match, or a subset of the second parameter
which is a list.
Examples: @IsMember
1. This example returns 1.
@IsMember("computer";"printer":"computer":"monitor")
2. This example returns 0.
@IsMember("computer":"Notes";"Notes":"printer":"monitor")
3. This example returns 1 if R&D is in the list in the Department field, returns 0 if R&D is not in the list.
@IsMember("R&D";Department)
4. This example returns 1, since Fred is a subset of a list.
@IsMember("Fred"; "Barney":"Wilma":"Fred")
@IsModalHelp
Indicates whether the current document is a modal Help document.
Syntax
@IsModalHelp
Return value
flag
Boolean
v Returns 1 (True) if the document is a modal Help document
v Returns 0 (False) if the document is not a modal Help document
Usage
A modal Help document is a document that displays as a dialog box that you must dismiss before you
can access any other currently open windows. Use @IsModalHelp to determine modality so you can
execute a formula only when the document is (or isnt) a modal Help document.
Language cross-reference
FieldHelp property of LotusScript NotesUIDocument class
@IsNewDoc
For a document being edited, indicates if the document has been saved to disk.
Syntax
@IsNewDoc
Return value
flag
Boolean
Usage
This function evaluates the current state of the document when it is used in toolbar button, hide-when,
section editor, window title, field, form, and form action formulas.
This functions returns 0 if the document has not yet been saved, regardless of how the document was
created. It always returns a 0, even if the document has been saved, when used in column, selection,
agent, and view action formulas.
Language cross-reference
IsNewDoc property of LotusScript NotesUIDocument class
Examples: @IsNewDoc
1. When used in a window title formula, this formula returns New Document while the document is
composed the first time. When a document is opened after it has been saved, this formula returns the
value of the Subject field.
@If(@IsNewDoc;"New Document";Subject)
2. If a new document is being created, the string New General Information appears in the window title.
When an existing document is opened, the string General Information for, then the contents of the
field EmpName, a slash, and then the contents of the field EmpNumber appear in the window title.
@If(@IsNewDoc; "New General Information"; "General Information for" + EmpName + "/" + EmpNumber)
@IsNotMember
Indicates if a text string (or a text list) is not contained within another text list. The function is
case-sensitive.
Syntax
@IsNotMember( textValue ; textListValue ) or @IsNotMember( textListValue1 ; textListValue2 )
Parameters
textValue
Text.
textListValue
Text list.
textListValue1
Text list.
textListValue2
Text list.
Boolean
v Returns 1 (True) if the textValue is not contained in textListValue
v Returns 0 (False) if it is contained
v If both parameters are lists, returns 1 if all elements of textListValue1 are not contained in textListValue2
Usage
In processing lists, @IsNotMember differs from a simple != test. != returns True if the pair-wise
comparison of two entities has no entities in common and False only if the pair-wise comparison of the
two entities finds all pairs to be equal. @IsNotMember does not perform a pair-wise comparison, but tests
each element in textListValue1against all the elements in the textListValue2 and returns False if it is equal
to one of them.
For further details on pair-wise operators, see Operations on lists in the Formula Language Rules
chapter.
@IsNotMember returns True only if no member of the first argument is contained in the second
argument.
Examples: @IsNotMember
1. This example returns 0.
@IsNotMember("computer";"printer":"computer":"monitor")
2. This example returns 1 if R&D is not in the list of values in the field name Department; returns 0 if
R&D is in the list.
@IsNotMember("R&D";Department)
3. This example returns Marketing in the Dept field if the current user is not contained in the list in the
SalesDepartment field; otherwise Sales is returned in the Dept field.
FIELD Dept:=@If(@IsNotMember(@Username;SalesDepartment); "Marketing"; "Sales");
4. This example returns 1 if both the [WebTeam] and [ManageFiles] roles are assigned to the current
user; it returns 0 if only one or neither of the roles is assigned to the user.
@IsNotMember("[WebTeam]":"[ManageFiles]";@UserRoles)
@IsNull
Tests for a null value. Returns true only if a value is a single text value that is null, otherwise it returns
false. This function also returns false if the value is an error.
Syntax
@IsNull( value )
Parameters
value
Boolean
v Returns 1 (True) if the value is a text value that is null
v Returns 0 (False) if the value is not a text value, not null, or is an error
Usage
This function is useful for checking for empty fields before using them in other functions in which they
might generate errors.
Examples: @IsNull
This function, when used as a field formula, finds the square root of each element in the text list in the
OriginalList field. @IsNull is first used to test the OriginalList field to ensure that it contains a value and
prevents the formula from calculating the square roots if it does not. If OriginalList contains 4: 25, the
result is 2; 5. If OriginalList is a null field, the result is a null field, not an error.
@If(@IsNull(OriginalList); @Nothing;
@Transform(OriginalList; "x";
@If(x >= 0; @Sqrt(x); @Nothing)))
@IsNumber
Indicates if a given value is a number (or a number list).
Syntax
@IsNumber( value )
Parameters
value
Return value
flag
Boolean
v Returns 1 (True) if the value is a number or a number list
v Returns 0 (False) if the value is not a number or a number list
Usage
This is a useful function for checking to see that you have assigned field data types correctly.
Language cross-reference
TypeName function of LotusScript language
@IsResponseDoc
Indicates whether a document is a response to another document.
Syntax
@IsResponseDoc
Return value
flag
Boolean
v Returns 1 (True) if the document is a response document
v Returns 0 (False) if the document is not a response document
v Returns 0 for new documents, since @IsResponseDoc doesnt recognize a document type until after the
document is saved
Usage
A response document is one that was composed with a form which has a type of either Response or
Response to Response. The designer uses the Form InfoBox to specify the type.
Language cross-reference
IsResponse property of LotusScript NotesDocument
Examples: @IsResponseDoc
This example returns Response if the document is a response; Topic if the document is not a response.
@If(@IsResponseDoc;"Response";"Topic")
@IsText
Indicates whether a value is text (or a text list).
Syntax
@IsText( value )
Return value
flag
Boolean
v Returns 1 (True) if the value is text or a text list
v Returns 0 (False) if the value is not text or a text list
Language cross-reference
TypeName function of LotusScript language
Examples: @IsText
1. This example returns 1.
@IsText("Blanchard & Daughters")
2. This example returns 1 if the field named BranchOffices contains the text string list New
Orleans:Houston:Dallas:Mobile.
@IsText(BranchOffices)
@IsTime
Indicates whether a value is a time-date (or a time-date list).
Syntax
@IsTime( value )
Parameters
value
Return value
flag
Boolean
v Returns 1 (True) if the value is a timedate or a timedate list
v Returns 0 (False) if the value is not a time-date or a time-date list
Language cross-reference
TypeName function of LotusScript language
@IsUnavailable
Indicates whether a field name exists in a document.
Syntax
@IsUnavailable( fieldname )
Parameters
fieldname
Return value
flag
Boolean
v Returns 1 (True) if the field name is not contained in the document
v Returns 0 (False) if the field name is contained in the document
Usage
Use @IsUnavailable to provide default values for fields in documents created with forms that do not
include a particular field name.
CAUTION:
Do not confuse @IsUnavailable with @Unavailable. @Unavailable deletes fields and can cause serious
damage if used unintentionally in place of @IsUnavailable.
Language cross-reference
HasItem method of LotusScript NotesDocument class
Examples: @IsUnavailable
This example returns Consultant if the field Dept does not exist; if Dept does exist, the value contained in
Dept is returned.
@If(@IsUnavailable(Dept);"Consultant";Dept)
@IsValid
Executes all validation formulas within the current form.
Syntax
@IsValid
Boolean
v Returns 1 (True) if all validation formulas resolve to True
v Returns 0 (False) if all validation formulas do not resolve to True
Usage
Use @IsValid to initiate execution of all of a forms validation formulas, as if the document were being
saved.
If validation formulas are added to a form after some documents have already been saved, you can use
@IsValid in a macro to determine which of those documents need corrections.
Language cross-reference
ComputeWithForm method of LotusScript NotesDocument class
Examples: @IsValid
You edit a form after its been in use for a while, and insert validation formulas into several fields. Now
you want to test existing documents to be sure they meet the field validation requirements. You can
create an additional field on the form and use this formula to indicate whether the document needs
corrections:
@If(@IsValid;"Ok";"Needs corrections")
@IsVirtualizedDirectory
Indicates whether virtualized directories are enabled for the current server.
Syntax
@IsVirtualizedDirectory
Return value
flag
Boolean
v Returns 1 (True) if virtualized directories are enabled
v Returns 0 (False) if virtualized directories are not enabled
Examples: @IsVirtualizedDirectory
This computed field displays the name of the current server if virtualized directories are enabled and a
message otherwise.
@if(@IsVirtualizedDirectory; @UserName;
@Return("Virtualized directories not enabled"))
@Keywords
Given two text lists, returns only those items from the second list that are found in the first list.
Parameters
textList1
textList2
separator
Text. One or more characters to be used as delimiters between words. @Keywords considers each
character (not the combination of multiple characters) to be a delimiter. For example, defining separator
as . , (period, space, comma) tells the function to separate the text at each period, space, and comma
into separate words.
When you do not specify a separator, the following word delimiters are used by default:
?. ,!;:[](){}<> (question mark, period, space, comma, exclamation point, semicolon, colon, (brackets,
parentheses, braces, quotation mark, and angle brackets)
A null separator, represented by an empty string (), tells the function to use no delimiters.
Return value
resultTextList
Text list. When a separator is in effect, either by default or specification, @Keywords parses textList1 into
words delimited by the separator and returns any word that exactly matches a keyword in textList2.
When no separator is in effect (when you specify a null separator), @Keywords returns any sequence of
characters in textList1 that matches a keyword specified in textList2.
Note: With Release 6, the order of the words returned in resultTextList match the order of textList1. Prior
to Release 6, the order of the words returned in resultTextList matched the order of textList2. To retain the
pre-Release 6 ordering of the resutlTextList, prepend the formula with another @Keywords function as
follows:
@Keywords(textList2;@Keywords(textList1;textList2))
Usage
When a keyword that you specify in textList2 is the very first word in the string you are searching AND
you specify separators, @Keywords returns null. To prevent this behavior, prepend textList1 with one of
the separators. For example, if you want to find the keyword, Sally, in a text list that contains employee
names and positions, use the following formula:
@Keywords(" " + " ,Mary Halen, Director of Sales":" ,Sally Hall, VP of
Marketing": " ,Joe Halzy, Order entry"; "Sally"; " ,")
This formula returns Sally. Note that one of the formulas separators, the space( ), is prepended to
textList1. This behavior does not occur if you accept the default separators or specify a null separator.
If one of the strings in textList2 contains any of the default delimiters, @Keywords will not return it. To
search for Harvard University, for example, add a null separator to the formula. This tells @Keywords to
When using the quotation mark separator (), precede it with a backslash (\) to indicate that the
quotation mark is a text constant.
This function is case-sensitive; you must standardize the case of textList1 and textList2 if you want case
to be ignored (use @LowerCase, @ProperCase or @UpperCase).
Examples: @Keywords
1. This formula returns Harvard;Yale.
@Keywords(@ProperCase("EPA Head speaks at Harvard and yale":"The UCLA Chancellor Retires":
"Ohio State wins big game":"Reed and University of Oregon share research facilities");
"Harvard":"Brown":"Stanford":"Yale":"Vassar":"UCLA")
2. This formula returns , a null string.
@Keywords("EPA Head speaks at Harvard,Yale":"UCLA Chancellor Retires":
"Ohio State wins big game":"Reed and University of Oregon share research facilities";
"harvard":"brown":"stanford":"vassar":"ucla")
3. This formula returns Harvard;Yale. It searches textList1 for the textList2 keywords that follow either a
comma or a space.
@Keywords("EPA Head speaks at Harvard, Yale hosts her next month":"UCLA Chancellor Retires":
"Ohio State wins big game":"Reed and University of Oregon share research facilities";
"Harvard":"Brown":"Stanford":"Yale":"UCLA";", ")
4. This formula returns Harvard;Yale University;UCLA.
@Keywords("EPA Head speaks at Harvard, Yale University hosts her next month":
"UCLA Chancellor Retires":"Ohio State wins big game":"Reed and University of Oregon
share research facilities";"Harvard":"Brown":"Stanford":"Yale University":"UCLA"; "")
5. This formula returns Mary Jones. when used in the Result field on a form that also contains the
Applicants field, which has a default value of: ,Mary Jones.:,John Chen.:,Miguel Sanchez..
@Keywords(Applicants;"Mary Jones.";",")
6. This formula returns Mary Jones. when used in the Result field on a form that also contains the
Applicants field, which has a default value of: ,Mary Jones., who works downtown, is being
interviewed on Friday.:,John Chen.:,Miguel Sanchez..
@Keywords("," + Applicants;"Mary Jones.";",")
7. This formula returns book.
@Keywords("<booklist> XML tag that represents a list of our books.":
"<book> XML tag that represents a book.":"<sale> XML tag that represents
the sale price of a book.";"book";"<>")
8. If list1 contains guava:eggplant:date:cherry:banana:apple and list2 contains
apple:banana:date, this formula, when triggered from a Release 6 or later client, returns date,
banana, apple. When triggered from a pre-Release 6 client, it returns apple, banana, date.
@Keywords(list1;list2)
9. If list1 and list2 contain the same text lists as in the previous example, this formula returns apple,
banana, date from all versions of Notes.
@Keywords(list2;@Keywords(list1;list2))
@LanguagePreference
Returns users specified preferred language setting.
Parameters
[ key ]
Keyword. Specify a category for which you would like to get the preferred language. The following
categories are available:
[REGION]
[CONTENT]
[ALTERNATENAME]
Return value
preferredlanguage
Text or Text list. Language and country code for users preferred setting. [REGION] language is set as the
default. If @LanguagePreference cannot find the language setting for the specified category, it returns the
language for [REGION].
Usage
@LanguagePreference is used to implement mechanisms for handling language-dependent features. A
database that is designed to store data in multiple languages can select the language in which the data
should be published for each user by using @LanguagePreference[Content].
@LanguagePreference supports the Web browser client. When the browser client calls
@LanguagePreference, it returns a list of languages specified in the Web browser. This returned list is
normalized based on the key parameter of the @function.
Language cross-reference
Language property of LotusScript NotesName class
Examples: @LanguagePreference
1. The following example returns fr if your region language setting is French.
@LanguagePreference([REGION])
2. The following example returns en if you call this function from the Web client and your Web
browsers accept language is English(United States).
@LanguagePreference([ALTERNATENAME])
Syntax
@LaunchApp( application )
Parameters
application
Text. The type of application you want to launch. Specify any one of the following:
Usage
If the requested application is already running, it will be brought to the front and it will have focus.
Language cross-reference
Shell function of LotusScript language
@LDAPServer
Returns the URL and port number of the LDAP listener in the current domain. Notes looks for this
information in several places, following this search sequence:
1. Searches on the current server.
2. Searches for the notes.ini variable labeled LDAPSERVER=.
3. Queries the administration server, which runs the LDAP service automatically, by default.
Syntax
@LDAPServer
Examples: @LDAPServer
The following code, when used as the default value for a field on a form that resides in a database
hosted by the ocean/bay server, displays LDAP://ocean.acme.com:379 when the form is accessed by a
Web browser. This indicates that the LDAP listener is located at port 379 for the current domain.
@LDAPServer
@Left
Searches a string from left to right and returns the leftmost characters of the string.
Parameters
stringToSearch
Text. The string where you want to find the leftmost characters.
numberOfChars
Number. The number of characters to return. If the number is 2, the first two characters of the string are
returned; if the number is 5, the first five characters are returned, and so on. If the number is negative,
the entire string is returned.
subString
Text. A substring of stringToSearch.@Left returns the characters to the left of subString. It finds subString by
searching stringToSearch from left to right.
Return value
resultString
Text. The leftmost characters in stringToSearch. The number of characters returned is determined by either
numberOfChars or subString. @Left returns if subString is not found in stringToSearch.
Language cross-reference
Left function of LotusScript language
Examples: @Left
1. This example returns Len.
@Left("Lennard Wallace";3)
2. This example returns Lennard Wal if the string in the Contact field is Lennard Wallace.
@Left(Contact;"la")
3. This example returns Tim if the string in the Author field is Timothy Altman.
@Left(Author;3)
4. This example returns Timothy if the string in the Author field is Timothy Altman.
@Left(Author;" ")
@LeftBack
Searches a string from right to left and returns a substring.
Syntax
@LeftBack( stringToSearch ; numToSkip ) or @LeftBack( stringToSearch ; startString )
Parameters
stringToSearch
Text. The string where you want to find the leftmost characters.
Number. Counting from right to left, the number of characters to skip. All the characters to the left of
that number of characters are returned. If the number is negative, the entire string is returned.
startString
Text. A substring of stringToSearch. All the characters to the left of startString are returned.
Return value
resultString
Text. The leftmost characters in stringToSearch. The number of characters returned is determined by either
numToSkip or startString.
Language cross-reference
StrLeftBack function of LotusScript language
Examples: @LeftBack
1. This example returns Lennard Wall.
@LeftBack("Lennard Wallace";3)
2. This example returns Lennard.
@LeftBack("Lennard Wallace"; " ")
3. This example returns Timothy Alt if the string in the Author field is Timothy Altman.
@LeftBack(Author;3)
@Length
Returns the number of characters in a text string.
Syntax
@Length( string ) or
@Length( stringlist )
Parameters
string
stringList
Return value
length
v If the parameter is a text string, @Length returns the number of characters in the specified string,
including spaces and punctuation.
v If the argument is a text list, @Length searches the list of strings and returns the number of characters
in each string as a number list.
Examples: @Length
1. This example returns 45.
@Length("The boy crossed the wide, but gentle, stream.")
2. This example returns the number list 0:5:3, which displays as 0;5;3 if the multi-value separator for the
field is a semicolon.
@Length("": "abcde": "xyz" )
3. This example returns the number list 16:10:22 if the contents of the fields From, Topic, and Date are
Stephen Brewster, News Flash, and @Now (where the current date is 04/01/2001 16:45:10 PM),
respectively. The number list displays as 16,10,22 if the multi-value separator for the field is a comma.
@Length(From: Topic: @Text(Date))
@Like
Matches a string with a pattern. It is case-sensitive and supports the NotesSQL ODBC driver.
Syntax
@Like( string ; pattern ) @Like( string ; pattern ; escape )
Parameters
string
pattern
Text. The sequence of characters to search for within string. May also contain any of the wildcard
characters listed below.
escape
Text. Optional. A character to use before a wildcard character to indicate that it should be treated literally.
Return value
flag
Number
v Returns 1 (True) if the pattern matches the string
v Returns 0 (False) if the pattern does not match the string
Language cross-reference
Like operator of LotusScript language
@Ln
Returns the natural log of a number. Natural logs use e (approximately 2.718282) as their base.
Syntax
@Ln( number )
Parameters
number
Number. May be any value greater than 0, and can contain up to 15 decimal places.
Return value
naturalLog
Usage
Use @Ln in formulas requiring natural logs, such as compound growth or loss.
Language cross-reference
Log function of LotusScript language
Examples: @Ln
This example returns 0.693147180559945.
@Ln(2)
@Locale
Returns information about language codes.
Parameters
[ action ]
[NotesLocale] without locale-tag returns a text list containing all the content language codes.
[NotesLocale] with locale-tag returns a text list or value containing each specified content language code,
or a null string if the code is not recognized. A code is recognized if it is exact regardless of case. If the
language is recognized but not the country or region, the language code alone is returned.
[AltNameLocale] without locale-tag returns a text list containing all the alternate name language codes.
[AltNameLocale] with locale-tag returns a text list or value containing each specified alternate user
language code, or a null string if the code is not recognized. A code is recognized if it is exact regardless
of case. The country or region is ignored where it is not part of the alternate user language code (most
cases).
[LanguageName] with locale-tag returns a text list or value spelling out the language for each specified
language code, or a null string if the code is not recognized.
[CountryName] with locale-tag returns a text list or value spelling out the country or region for each
specified language code, or a null string if the code has no country or region, or it is not recognized.
[LocaleName] with locale-tag returns a text list or value spelling out the language and country (or region),
if applicable, for each specified language code, or a null string if the code is not recognized. The country
or region is in parentheses and immediately (no space) follows the language.
[LocaleName] : [NotesLocale] (concatenating these two keywords) returns a text list containing, for each
content language code, the language name, the country or region name in parentheses, a vertical bar, and
the language code. This list can be used in a keyword field where the locale name is the name and the
language code is the alias.
[LocaleName] : [AltNameLocale] (concatenating these two keywords) returns a text list containing, for
each alternate name language code, the language name, the country or region name in parentheses, a
vertical bar, and the language tag. This list can be used in a keyword field where the locale name is the
name and the language code is the alias.
locale-tag
Language cross-reference
Language property of LotusScript NotesName class
Examples: @Locale
1. The following formulas return French.
@Locale([LanguageName]; "fr")
@Log
Returns the common logarithm (base 10) of any number greater than zero.
Syntax
@Log( number )
Parameters
number
Return value
commonLog
Usage
Use @Log in any formula requiring a common log, such as the formula to calculate the root of a number.
@Log is the reciprocal of scientific notation.
Examples: @Log
1. This example returns 0.602059991327962.
@Log(4)
2. This example returns 14.
@Log(1.0E+14)
Syntax
@LowerCase( string )
Parameters
string
Return value
lowerCaseString
Usage
This function is useful when you want to search for a particular value and cannot predict whether it
appears in lowercase or uppercase letters, or a combination of the two. You can also use it as an input
translation formula to convert the contents of a field to lowercase.
Language cross-reference
StrConv function of LotusScript language
Examples: @LowerCase
1. This example returns juan mendoza.
@LowerCase("Juan Mendoza")
2. This example returns arm chair if the Furniture field contains Arm Chair, Arm chair, arm chair,
or ARM CHAIR, or any other variation.
@LowerCase(Furniture)
3. This example returns fletcher if William Fletcher is the name associated with the current hierarchical
User ID.
@LowerCase(@Right(@Name([CN];@UserName); " "))
@MailDbName
Returns the name of the Domino server and the name of the current users Mail database.
Syntax
@MailDbName
Return value
server ; path
Usage
This function works in any formula except column formulas. When a formula runs on a server, the server
is considered the current user, so @MailDbName returns the name of the server.
The returned value is formatted as a twoitem text list specifying the Server;Directory\Database.NSF, as
in:
ACMEMAIL;LEGAL\DLEE.NSF
If the database is stored on the users own computer, Notes/Domino returns the null string for the server
name. For example, dial up user Debbie Lee may keep a local replica of her Mail database on her
workstation; when she is set up for workstationbased mail, @MailDbName returns:
;DLEE.NSF
This is useful in applications that send mail; for example, you can use it to determine whether the current
user is set up for serverbased mail, and determine the appropriate course of action based on the result.
Language cross-reference
GetUserInfo method of LotusScript NotesRegistration class
Examples: @MailDbName
1. This example returns ;MTSEN.NSF if the users mail is in the MTSEN.NSF database stored on the
users own computer, and the user is set up to use workstationbased mail.
@MailDbName
2. This example returns SALES1;MAIL\MTSEN.NSF if the users mail is stored in MTSEN.NSF in the
MAIL directory on the SALES1 server, and the user is set up to use serverbased mail. If the database
is stored at the servers root directory (that is, it is not stored in a subdirectory), the result would be
SALES1;MTSEN.NSF.
@MailDbName
3. This example returns MTSEN.NSF, the file name, since this is the last element in the list returned by
@MailDbName.
@Subset(@MailDbName;1)
@MailEncryptSavedPreference
Indicates whether the user has selected Encrypt saved mail in the User Preferences dialog box.
Syntax
@MailEncryptSavedPreference
Boolean
v Returns 1 (True) if Encrypt saved mail is selected
v Returns 0 (False) if Encrypt saved mail is not selected
Usage
@MailEncryptSavedPreference is used in the Mail template to determine whether to encrypt saved
memos. This function is not available in column formulas, selection formulas, or selective replication
formulas.
Examples: @MailEncryptSavedPreference
You design your own Mail form. To determine whether memos created with your form and then saved
should be encrypted, use @MailEncryptSavedPreference to determine the current users preference. This
returns 1 if the Encrypt saved mail check box is selected in the User Preferences dialog box, and 0 if the
Encrypt saved mail check box is not selected.
@MailEncryptSavedPreference
@MailEncryptSentPreference
Indicates whether the user has selected Encrypt sent mail in the User Preferences dialog box.
Syntax
@MailEncryptSentPreference
Return value
flag
Boolean
v Returns 1 (True) if Encrypt sent mail is selected
v Returns 0 (False) if Encrypt sent mail is not selected
Usage
@MailEncryptSentPreference is used in the Mail template to determine whether to encrypt sent memos.
This function is not available in column formulas, selection formulas, or selective replication formulas.
Language cross-reference
EncryptOnSend property of LotusScript NotesDocument class
Examples: @MailEncryptSentPreference
You can design your own Mail form. To determine whether outgoing memos should be encrypted
automatically, use @MailEncryptSentPreference to determine the users preference. This returns 1 if the
Encrypt sent mail check box is selected in the User Preferences dialog box, and 0 if the Encrypt sent
mail check box is not selected.
@MailSavePreference
Indicates which option the user has selected for the Save sent mail setting in the User Preferences
dialog box.
Syntax
@MailSavePreference
Return value
flag
Integer
v Returns 0 if Dont keep a copy is selected
v Returns 1 if Always keep a copy is selected
v Returns 2 if Always prompt is selected
Usage
@MailSavePreference is used in the Mail template to determine whether to save copies of outgoing
memos. This function is not available in column formulas, selection formulas, or selective replication
formulas.
Language cross-reference
SaveMessageOnSend property of LotusScript NotesDocument class
Examples: @MailSavePreference
You design your own Mail form. To determine whether outgoing memos should be automatically saved,
use @MailSavePreference to determine the users preference. This returns 2 if the Save sent mail list has
Always prompt selected, 1 if the Save sent mail list has Always keep a copy selected, and 0 if the
Save sent mail list has Dont keep a copy selected.
@MailSavePreference
@MailSend
There are two ways to use @MailSend:
v When used with no parameters, @MailSend mails the current document (the one being processed when
the @function is evaluated) to the recipient designated in the documents SendTo field. The document
must have a SendTo field.
v When used with one or more parameters, @MailSend composes a new mail memo based on the
information you supply in the arguments list, and sends it to the recipients listed in the sendTo,
copyTo, and blindcopyTo arguments.
Syntax
@MailSend @MailSend( sendTo ; copyTo ; blindCopyTo ; subject ; remark ; bodyFields ; [ flags ] )
copyTo
Text or text list. Optional. The copy recipient(s) of the mail memo.
blindCopyTo
Text or text list. Optional. The blind copy recipient(s) of the mail memo.
subject
Text. Optional. The text you want displayed in the Subject field. This is equivalent to the Subject field on
a mail memo; the message is displayed in the Subject column in the views in the recipients mail
databases.
remark
Text. Optional. Any text you want at the beginning of the body field of the memo.
bodyFields
Text. The names of one or more fields from the current document that you want included in the mail
memo. The fields must be of type text or text list, and are appended to the memo in the order in which
you list them. (You can store @Text of a numeric field in a variable and use the variable name as a field
name.) Enclose each field name in quotation marks. If you want to list multiple fields, use the list format:
description:issues:resolution. If you store the name of the field in a variable, omit the quotation
marks here.
When you use the [IncludeDocLink]flag (described below) to include a link to the current document,
you should set thebodyFields parameter to null (). If Notes/Domino cannot locate a field by name, it
uses the string literal instead.
[ flags ]
Keyword. One or more flags indicating the priority and security of the memo. If you specify multiple
flags, format them as a list, as in [SIGN]:[PRIORITYHIGH]:[RETURNRECEIPT]. Enclose each flag in
square brackets, as shown.
[SIGN]
Electronically sign the memo when mailing it, using information from the users ID. Signing does not
occur unless you include this flag. This flag cannot be used in Web applications.
[ENCRYPT]
Encrypt the document using the recipients public key, so that only the recipient whose private key
matches can read the document. Encryption does not occur unless you include this flag. This flag cannot
be used in Web applications.
Immediately routes the message to the nexthop server, as defined by the combination of Mail
Connection records and server records. If a phone call has to be made in order to route the message, then
the call is placed immediately, regardless of the schedule set in the Remote Connection record. If you
omit this flag, the priority defaults to Normal.
[PRIORITYNORMAL]
Routes the message to the nexthop server based on the schedule defined in the Mail Connect records. If
the recipients mail file resides on a server on the same Domino network, then delivery occurs
immediately. If you omit this flag, the priority defaults to Normal.
[PRIORITYLOW]
Routes the message overnight if the recipients mail file does not reside on a server on the same
Notes/Domino network. If the recipients mail file does reside on a server on the same Notes/Domino
network, then delivery occurs immediately. Low Priority mail can also be controlled by a Notes/Domino
environment variable called MailLowPriorityTime=x, where x is equal to a number from 0 to 23. When
placed in the server notes.ini file, this variable tells the server when to route Low Priority mail. If you
omit this flag, the priority defaults to Normal.
[RETURNRECEIPT]
Notify the sender when each recipient reads the message. No receipt is returned unless you include this
flag.
[DELIVERYREPORTCONFIRMED]
Notify the sender whether delivery of the memo was successful or not. By default, the Basic delivery
report is used, which notifies the sender only when a delivery failure occurs.
[INCLUDEDOCLINK]
Include a link pointing to the document that was open or selected when @MailSend was used. You must
include this flag if you want that document linked to the mail memo. A new document must be saved.
Usage
Use @MailSend in agents, form actions, form events, view actions, view events, and toolbar buttons.
@MailSend is especially useful with scheduled agents as a means of sending mail at a predetermined
interval; for example, to send reminders about a departmental meeting. One view from the database must
be selected as the Default when database is first opened for the scheduled agent to work correctly. This
function does not work in column, selection, hide-when, or window title formulas.
NoExternalApps=1
then any formula involving @MailSend is disabled. The user doesnt see an error message; the formula
fails to execute.
Language cross-reference
Send method of LotusScript NotesDocument class
Examples: @MailSend
1. This formula sends a memo to David Lee with a blind copy to Joseph Smith in Support. The memo is
titled Status Report, and its body contains the message Sorry its late! plus the contents of the
STATUS and PLANS fields from the current document. The document is mailed with the following
options: it is signed, delivery confirmation is requested, and a return receipt will be sent when each
recipient reads the memo. The recipients are listed using distinguished naming syntax (available to
Release 3 users only). The copyTo information was omitted, and was replaced with the null string
because additional arguments follow.
@MailSend("David Lee/";"";"Joseph Smith/Support";"Status Report"; "Sorry
its late!"; "STATUS":"PLANS"; [SIGN] : [DELIVERYREPORTCONFIRMED] : [RETURNRECEIPT])
2. This formula sends a memo to Mary Tsen and to Joseph Smith in Support. The subject uses the text
stored in the current documents TOPIC field, and the body of the memo draws from the
COMMENTS field. The copyTo, blindCopyTo, and remark arguments were omitted, and were
replaced with null strings because additional arguments still followed. The flags were omitted, but
because no arguments followed their position, the null string was not needed.
@MailSend("Mary Tsen/":"Joseph Smith/Support";"";"";TOPIC;""; "COMMENTS")
3. This formula sends a memo to Mary Tsen with the message Follow this link in the Subject field, and
a link to the original document in the Body field.
@MailSend("Mary Tsen/";"";"";"Follow this link";"";"";[IncludeDocLink])
4. This agent formula sends Martha OConnell the contents of the Comments rich text field in a memo
with the subject Feedback. The agent is triggered on an Action menu selection event and its target is
the selected documents.
@MailSend("Martha OConnell/MA/Acme";"";"";"Feedback";"";"Comments")
@MailSignPreference
Indicates whether the user has selected Sign sent mail in the User Preferences dialog box.
Syntax
@MailSignPreference
Boolean
v Returns 1 (True) if Sign sent mail is selected
v Returns 0 (False) if Sign sent mail is not selected
Usage
@MailSignPreference is used in the Mail template to determine whether to attach an electronic signature
to outgoing memos. This function is not available in column formulas, selection formulas, or selective
replication formulas.
Language cross-reference
SignOnSend property of LotusScript NotesDocument class
Examples: @MailSignPreference
You design your own Mail form. To determine whether outgoing memos should be electronically signed,
use @MailSignPreference to determine the users preferences. This returns 1 if the Sign sent mail check
box is selected in the User Preferences dialog box, and 0 if the Sign sent mail check box is not selected.
@MailSignPreference
@Matches
Tests a string for a pattern string. Because the pattern string can contain a number of wildcard
characters and logical symbols, you can test for complex character patterns.
Syntax
@Matches( string ; pattern )
Parameters
string
Text. The string you want to scan in quotes. You can also enter the field name of a field that contains the
string you want to scan; do not surround the field name in quotes.
pattern
Text. The pattern you want to scan for in stringsurrounded by quotation marks. May contain wildcard
characters and symbols (see table below). The following symbols require a preceding backslash unless the
pattern is enclosed in braces { } as a set: ?, *, &, !, |, \, +. The symbols require two preceding backslashes
instead of one if the pattern is specified as a literal. This is because the backslash is an escape character in
string literals, so \? passes ? to the matching engine, where it is treated as a wildcard, while \\?
passes \? to the matching engine, where it is treated as a question mark character.
Return value
flag
Boolean
Symbol Use
C Where C is any character. Matches any single, nonspecial character C
? Matches any single character
* Matches any string (any number of characters)
{ABC} Matches any character in set ABC
{AFLR} Matches any character in the sets A...F and L...R
+C Matches any number of occurrences of C
! Complements logical meaning of the pattern (logical NOT)
| Performs logical OR of two patterns
& Performs logical AND of two patterns
Note: When specifying sets, be sure to enclose them in { } (curly braces). For example, the set A...F is
represented as {A-F}.
Pattern Matches
ABC ABC
{ABC}{ABC} Two capital letters
A?C Any threecharacter string that starts with A and ends with C
??? Any threecharacter string
+? Any string, including the null string
+?{AZ} Any string that ends in a capital letter
+{!AZ} Any string that does not contain a capital letter
Language cross-reference
Like operator of LotusScript language
Examples: @Matches
1. This example returns 0.
@Matches("A big test";"a?test")
2. This example returns 1.
@Matches("A big test";"a?????test")
3. This example converts the contents of the State field to lowercase, and returns 1 for any value in the
field that contains mont, for example Vermont or Montana.
@Matches(@Lowercase(State);"*mont*")
4. This example is the default value formula for a field named SalesNumber. The formula returns the
number 224 if the content of the Division field is either Central or Midwest. If the content of Division
is anything else, the formula returns the number 124.
@If(@Matches(Division;"Central | Midwest");224;124)
Note: The validation error message is also triggered if the user enters a backslash, underscore, or
square brackets because specifying A-z, specifies all ASCII characters between the uppercase A and
lowercase z. The backslash, underscore, and square brackets are included in this set of characters.
6. This code, when added as the validation formula for the US_State editable text field, displays the
error message, Entry must be a valid two-letter state abbreviation if the user enters anything besides
two upper-case letters.
@If(@Matches(US_State;"{A-Z}{A-Z}");@Success;@Failure("Entry must be a valid two-letter state abbreviation"))
@Max
Returns the largest number in a single list, or the larger of two numbers or number lists.
Syntax
@Max( number1 )
Parameters
number1
number2
Return value
maxNumber
(Two parameters) Number or number list. Either number1 or number2, whichever is larger. If the
parameters are number lists, @Max returns a list that is the result of pairwise computation on the list
values.
Usage
When using this function with a number list constant, remember that the list concatenation operator takes
precedence over other operators. Enclose negative numbers in parentheses.
For more information, see List concatenation operator in the Formula Language Rules chapter.
Examples: @Max
1. This example returns 3.
@Max(1;3)
2. This example returns 99;6;7;8.
@Member
Given a value, finds its position in a text list.
Syntax
@Member( value ; stringlist )
Parameters
value
stringlist
Text list.
Return value
position
Number
v Returns 0 if the value is not contained in stringlist
v Returns 1 to n if the value is contained in the stringlist, where 1 to n is the position of the value in the
stringlist
Examples: @Member
1. This example returns 0.
@Member("Sales";"Finance":"Service":"Legal")
@Middle
Returns any substring from the middle of a string. The middle is found by scanning the string from left
to right, and parameters determine where the middle begins and ends.
Syntax
@Middle( string ; offset ; numberchars ) @Middle( string ; offset ; endstring ) @Middle( string ; startString ;
endstring ) @Middle( string ; startString ; numberchars )
Parameters
string
offset
Number. A character position in string that indicates where you want the middle to begin, always
counting from left to right. The middle begins one character after the offset.
startString
Text. A substring of string that indicates where you want the middle to begin, always counting from left
to right. The middle begins one character after the end of startString.
numberchars
Number. The number of characters that you want in the middle. If numberchars is negative, the middle
starts at offset or startString and continues from right to left. If numberchars is positive, the middle starts
one character past the offset or startString and continues from left to right.
endstring
Text. A substring of string that indicates the end of the middle. @Middle returns all the characters
between offsetand endstring, or between startString and endstring.
Return value
middle
Text. The substring from the middle of string,which begins at the offset or startString you specify and ends
at the endstring you specify, or after the numberchars have been reached.
Language cross-reference
Mid function of LotusScript language
Examples: @Middle
1. This example returns h C. The offset is positioned at the t (the fourth character from the left), and
the count starts with the first character after the offset, moving from left to right.
@Middle("North Carolina";4;3)
@MiddleBack
Returns any substring from the middle of a string. The middle is found by scanning the string from right
to left, and parameters determine where the middle begins and ends.
Syntax
@MiddleBack( string ; offset ; numberchars ) @MiddleBack( string ; offset ; endstring ) @MiddleBack( string ;
startString ; endstring ) @MiddleBack( string ; startString ; numberchars )
Parameters
string
offset
Number. A character position in string that indicates where you want the middle to begin, always
counting from right to left. The middle begins one character after the offset. Always add 1 to this number;
the end of the string is marked by one non-visible character and must be counted in the offset.
startString
Text. A substring of string that indicates where you want the middle to begin, always counting from right
to left. The middle begins one character after the end of startString.
numberchars
Number. The number of characters that you want in the middle. If numberchars is negative, the middle
starts at offset or startStringand continues from right to left. If numbercharsis positive, the middle starts one
character past the offset or startStringand continues from left to right.
endstring
Text. A substring of string that indicates the end of the middle. @MiddleBack returns all the characters
between offsetand endstring, or between startString and endstring.
Text. The substring from the middle of string, which begins at the offset or startStringyou specify and ends
at the endstring you specify, or after the numberchars have been reached.
Examples: @MiddleBack
1. This example returns Alt if the content of the Author field is Timothy Altman.
@MiddleBack(Author;" ";3)
2. This example returns an empty string if the content of the Author field is any string with no spaces,
for example Smith.
@MiddleBack(Author;" ";3)
3. This example returns from right to left with a space before from.
@MiddleBack("Middleback searches the string from right to left"; "ing";25)
4. This example returns searches the string .
@MiddleBack("@MiddleBack searches the string from right to left"; "from"; -20)
5. This example returns is the with spaces before and after is the. The return string is everything
from the fifth to the last character through the character after This.
@MiddleBack("This is the text"; 5; "This")
6. This example returns the with spaces before and after the. The return string is everything before
text and after is.
@MiddleBack("This is the text"; "text"; "is")
@Min
Returns the smallest number in a single list, or the smaller of two numbers or number lists.
Syntax
@Min( number1 )
Parameters
number1
number2
Return value
minNumber
(Two parameters) Number or number list. Either number1 or number2, whichever is smaller. If the
parameters are number lists, @Max returns a list that is the result of pairwise computation on the list
values.
For more information, see List concatenation operator in the Formula Language Rules chapter.
Examples: @Min
1. This example returns 35.
@Min(35;100)
2. This example returns 5;2;3;3.
@Min(99:2:3;5:6:7:8)
3. This example returns the contents of the field containing the smallest value. If Precinct1 contains
150,000 and Precinct2 contains 100,000, then this formula returns 100,000.
@Min(Precinct1;Precinct2)
4. This example returns 85,000 if 100,000 is the smallest number contained in either of the fields
AreaAPopulation or AreaBPopulation, and the field DistrictPopulation contains the value 15,000.
@Min(AreaAPopulation;AreaBPopulation) DistrictPopulation
5. This example returns -3.5;-35;54.
@Min((-3.5):(-35):100;(-2):45:54)
6. This example returns 2.
@Min(99 : 2 : 3)
@Minute
Extracts the number of minutes from the specified timedate.
Syntax
@Minute( timedate )
Parameters
time-date
Time-date.
Return value
minutes
Number. The number of minutes in the minute part of the time. Returns -1 if the time-date provided
contains only a date and not a time value.
Language cross-reference
Minute function of LotusScript language
Examples: @Minute
1. This example returns 30.
@Minute([9:30])
2. This example returns 56 if the Time field contains 8:56:34 P.M.
@Minute(Time)
3. This example returns 59 if the Date field contains: 7/30/95 9:59:59.
@Modified
Returns a timedate value indicating when the document was last edited and saved.
Syntax
@Modified
Return value
lastModified
Time-date. The date when the current document was last modified.
Usage
@Modified works correctly in column formulas and computed-for-display formulas.
When used in computed fields, @Modified returns a value representing the next-to-last time the
document was saved. For example, if you modified and saved a document on the mornings of May 5th
and 6th, then accessed the document in the afternoon on May 6th, the @Modified computed field would
return the May 5th modification date, since the 5th was the next-to-last time the document was saved.
This function does not work in navigators, mail agent, paste agent, hide-when, section editor, or form
formulas.
@Modified is similar to @Accessed, which indicates the last time a document was accessed for reading or
writing.
Language cross-reference
LastModified property of LotusScript NotesDocument class
Examples: @Modified
1. This example returns 9/30/95 11:00:00 AM if the document was last saved on September 30, 1995 at
11:00 A.M.
@Modified
2. This example returns a string made up of the contents of the Topic field, then a space, then the string
Last Edited: and then the timedate value of the last time the document was saved, converted to text.
Topic + " " + "Last Edited: " + @Text(@Modified)
@Modulo
Returns the remainder of a division operation.
Syntax
@Modulo( number1 ; number2 )
number2
Return value
remainder
Number or number list. The remainder of number1 divided by number2.If the parameters are number lists,
@Modulo returns a list that is the result of pairwise computation on the list values. The sign of the
result is always the same as the sign of the number1.
Usage
A common use of @Modulo is to determine whether a number is odd or even; if the result of
@Modulo(number;2) is 1, the number is odd; if the result is 0, the number is even.
When using this function with a number list, the list concatenation operator takes precedence over any
other operators; negative numbers must be enclosed in parentheses.
For more information, see List concatenation operator in the Formula Language Rules chapter.
Language cross-reference
Mod operator of LotusScript language
Examples: @Modulo
1. This example returns 1.
@Modulo(4;3)
2. This example returns 0.
@Modulo(4;2)
3. This example returns 2.
@Modulo((14);3)
4. This example returns -1;2;3;-3.
@Modulo((-4):6:8:(-9);3:4:5:6)
@Month
Extracts the number of the month from the specified timedate.
Syntax
@Month( timedate )
Parameters
time-date
Time-date.
Number. The number of the month. Returns -1 if the time-date provided contains only a time value and
not a date.
Language cross-reference
Month function of LotusScript language
Examples: @Month
1. This example returns 1.
@Month([1/15/88])
2. This example returns 12 if it is December.
@Month(@Now)
3. This example returns 2 if it is any date in December other than the 30th or the 31st. If it is December
30th or 31st, returns 3.
@Month(@Adjust(@Now;2;2;2;2;2;2))
4. This formula returns a formatted date string based on the contents of the dueDate field. For example,
if dueDate contains 06/26/95 the formula returns June 26, 1995. If dueDate contains 01/24/96
3:40:43 P.M., the formula returns January 24, 1996.
space:= " ";
comma:=",";
month:=@Select(@Month(dueDate);"January";"February";"March";
"April";"May";"June";"July";"August";"September";"October";
"November";"December");
day:=@Text(@Day(dueDate));
year:=@Text(@Year(dueDate));
month + space + day + comma + space + year
@Name
Allows you to manipulate hierarchical names. You can abbreviate the canonical format of a name, expand
an abbreviated name to its canonical format, identify particular components within the name, and reverse
the order of the components so that you can categorize a view by hierarchical names.
Enables you to convert a name between the Domino and LDAP formats.
Syntax
@Name( [ action ] ; name )
Parameters
[ action ]
Keyword. Indicates what you want done to the name -- whether you want to expand it, abbreviate it,
convert it, and so on (see list of possible actions below).
[A]
Returns the ADMD component (administration management domain name) of a hierarchical name.
Abbreviates a hierarchical name, removing the component labels. This saves space in the display, and
looks friendlier.
[ADDRESS821]
Returns an Internet address in the format based on RFC 821 Address Format Syntax regardless of
whether the original address was in RFC 821 or RFC 822 form. Case must be exact.
[C]
[CANONICALIZE]
Expands an abbreviated name, adding in whatever components are missing, as well as their labels.
Missing components are taken from the current user ID, not from the Domino Directory.
[CN]
v Returns the common name component of a Domino name.
v Returns the local part of an Internet address in the format based on RFC 821 Address Format Syntax.
v Returns the phrase part of an Internet address in the format based on RFC 822 Address Format Syntax.
[G]
Returns the given name component (the first name) of a hierarchical name.
[HIERARCHYONLY]
Strips the CN component of a hierarchical name and returns the remaining components.
[I]
[LP]
Returns the LocalPart of a standard Internet address based on RFC 822 Address Format Syntax.
[O]
[OU n ]
Returns the specified organizational unit component of a hierarchical name; n can be from 1 to 4, as in
OU1. In the canonical form of the name, the OU components are not numbered; however, they are
[P]
Returns the PRMD component (private management domain name) of a hierarchical name.
[PHRASE]
Returns the Phrase part of a standard Internet address based on RFC 822 Address Format Syntax.
[Q]
[S]
[TOAT]
Returns the LDAP AttributeType name when a Domino field name is provided.
[TODATATYPE]
Returns the Domino data type name when an LDAP Syntax name is provided.
[TOFIELD]
Returns the Domino field name when an LDAP AttributeType name is provided.
[TOFORM]
Returns the Domino form name when an LDAP ObjectClass name is provided.
[TOKEYWORD]
Reverses the order in which the naming components are displayed, and replaces slashes with
backslashes: Country\Organization\Organization Unit... This is useful when you want to categorize a
view by the components of a users hierarchical name (backslashes represent subcategories in views). The
[TOKEYWORD] option does not return the Common Name portion of the user name.
[TOOC]
[TOSYNTAX]
Returns the LDAP Syntax name when a Domino data type name is provided.
name
Text or names. A user or server name, entered in any form (Lotus Notes/Domino determines the full
hierarchical name and then returns the requested components) or an LDAP AttributeType, ObjectClass, or
Syntax name or a Domino form, subform, field, or data type name to be converted from LDAP to
Domino format or vice-versa.
Usage
@Name is particularly useful for abbreviating hierarchical names in a view.
A hierarchical name is qualified with a series of components identifying the full name, organizational
unit, organization, and country or region. Using hierarchical names guarantees that each user and server
has a unique name.
As the database designer, you are responsible for controlling how user names are entered and displayed
within Notes applications. For simplicity, you should allow users to enter names in abbreviated form;
then you can use @Name to expand the name to its canonical format. You should also display names in
abbreviated form, using @Name to convert the stored canonical format of the name to its abbreviated
form.
When you use a Names, Readers, or Authors field, Lotus Notes/Domino automatically converts
hierarchical names to an appropriate format for display and storage. If the user enters an abbreviated
name, Lotus Notes/Domino expands it to canonical format when storing it; the name is always displayed
on a form in abbreviated format.
When you display the contents of a hierarchical name field in a view there is no automatic conversion;
the entire canonical format of the name is displayed. You may want to convert the name to its
abbreviated form with @Name.
If you are using @Name to parse an Internet address, the address must conform to the format based on
the standard RFC 821 or RFC 822 Address Format Syntax.
Note: If you attempt to use the parameters A, G, I, P, Q, or S in Lotus Notes/Domino with existing user
IDs, it may appear as though the parameters do not work. These parameters were added to take
advantage of the addressing used for external mail and gateway products. When a mail message is
received within Lotus Notes/Domino from an external mail source, the naming convention can include
additional components. The @Name function can be used to manipulate the hierarchical name, including
these additional components. Domino IDs and names do not use these additional components, therefore,
it is not possible to use these six parameters with a standard Domino ID and name.
Below is an example of a full hierarchical name that takes advantage of every parameter.
G=Joe/I=JS/S=Smith/Q=Jr/CN=Joseph
Smith/OU=Assembly/OU=Engineering/O=Acme/P=PrivAdmin/ A=PubAdmin/C=US
Examples: @Name
1. This example returns Mary Tsen/Illustration/ Documentation/Development/R&D/WorkSavers/US.
@Name([ABBREVIATE];AUTHOR)
If a user is looking at a document where the AUTHOR field contains the hierarchical form of Mary
Tsens name.
2. This example returns Mary Tsen.
@Name([CANONICALIZE];"Mary Tsen")
Since there is no slash following the name, it is a nonhierarchical name and has no additional
components.
3. This example returns CN=MaryTsen/
OU=Illustration/OU=Documentation/OU=Development/OU=R&D/O=Acme/C=US if that is the
current user ID. The hierarchy of the current user ID is appended to the name; no lookup occurs in
the Domino Directory.
@Name([CANONICALIZE];"Mary Tsen/")
4. This example returns Mary Tsen in an informational dialog box format, if the AUTHOR field in the
document contains: CN=Mary Tsen/OU=Illustration/O=Acme.
@Prompt([Ok]; "Common Name"; @Name([CN]; AUTHOR))
5. This example returns Development.
@Name([OU2];AUTHOR)
6. This example returns US\Acme\R&D\Development\Documentation\Illustration. The slashes are
now backslashes, which allow the naming components to be used as subcategories in a view. The
common name component is not returned.
@Name([TOKEYWORD];AUTHOR)
7. This example returns SStreitfeld if the User_Name field contains this Internet address in RFC 822
format Streitfeld, Sara (Miami) <SStreitfeld@gazette.com> .
@Name([LP];User_Name)
8. This example returns Streitfeld, Sara (Miami) if the User_Name field contains this Internet address
in RFC 822 format Streitfeld, Sara (Miami) <SStreitfeld@gazette.com> .
@Name([Phrase];User_Name)
9. This example returns SStreitfeld@gazette.com if the User_Name field contains this Internet address in
RFC 822 format Streitfeld, Sara (Miami) <SStreitfeld@gazette.com> .
@Name([ADDRESS821];User_Name)
10. This example returns Cam/Lotus If the User_Name field contains John Doe/Cam/Lotus.
@Name([HIERARCHYONLY];User_Name)
11. This example returns secretary, the LDAP AttributeType name for the Domino term, assistant.
@Name([TOAT];"assistant")
12. This example returns Internet Address, the Domino term equivalent to the LDAP AttributeType
name mail.
@Name([TOFIELD];"mail")
13. This example returns Number, the Domino term equivalent to the LDAP data type, Integer.
@Name([TODATATYPE];"Integer")
14. This example returns Directory String, the syntax used in the LDAP directory for the Domino data
type Text.
@Name([TOSYNTAX];"Text")
Syntax
@NameLookup( [ lookupType ] ; username; itemtoreturn )
Parameters
[ lookupType ]
Keyword. Specifies the type of lookup to perform. Supply one or more of the following keywords:
[NoUpdate]
Default. Returns a list of user names. Corresponds to NAME_LOOKUP_NOUPDATE flag for Notes API.
You can specify this keyword along with the other keywords excluding[ForceUpdate].
[ForceUpdate]
Forces the name space (view) to be updated. Corresponds to NAME_LOOKUP_UPDATE flag for Notes
API. You can specify this keyword along with the other keywords excluding[NoUpdate].
The following keywords can be used along with the [NoUpdate] or [ForceUpdate].
[NoSearching]
Searches only the first Domino Directory containing the ($Users) view, which is the local Names.nsf
database, and returns a list of single text values for each specified user name. This keyword specifies to
not retrieve values from the mail servers directory. An empty string is returned for no match found.
Corresponds to NAME_LOOKUP_NOSEARCHING flag for Notes API.
[Exhaustive]
Searches all Domino Directories listed in the Notes Directory Assistance and returns all information in a
text list. This keyword returns values from the local Names.nsf database as well as the mail servers
directory. If the mail server is unavailable, it retrieves values from the current name server. If you are
using LDAP, it also retrieves values from the LDAP directory. The users value is omitted if there is no
match found.
[TrustedOnly]
Searches only those Domino Directories that contain trust information and returns a list of single text
values for each specified user name. An empty string is returned for no match found. Corresponds to
NAME_LOOKUP_TRUSTED_NAMESPACES flag for Notes API.
username
Text or text list. Specify primary or alternate Notes/Domino user names to retrieve their information
from the Domino Directory.
itemtoreturn
Return value
valuelist
Text list. When other flags besides [Exhaustive] have been specified, @NameLookup returns a list of
single values for each specified user. An empty string is returned for no match found. When [Exhaustive]
has been specified, @NameLookup returns a list of all information matched for the specified user. No
value is returned for unmatched users. To display the return values in a dialog box using @Prompt,
enclose this function in an @Text function.
Usage
@NameLookup cannot be used in form selection and view column formulas.
All the users from secondary directories, including the LDAP directory, need to be authenticated first,
and then authorized to access a Notes/Domino database administered by the Domino server. The
Directory Assistance derived from the Master Domino Directory uses trusted name rules to authenticate
users. Once a user name is authenticated, it is added to the list of trusted names. This user name is then
compared to the ACL for authorization.
For more information on searching the LDAP directory, see Setting up Notes to search an Internet
directory for addresses in the Lotus Notes Help.
Examples: @NameLookup
You have three Domino Directories on your local environment, namely, Names_A.nsf, Names_B.nsf, and
Names_C.nsf. Each Directory has the following entries:
Item: Jones_B2
User: Smith User: Smith Does not exist User: Smith
@Narrow
Converts full-pitch alphanumeric characters (double byte characters -- DBCS) in the specified string to
half-pitch alphanumeric characters (single byte characters -- SBCS). This function works in Japanese,
Korean, Simplified Chinese, and traditional Chinese environments. In the Japanese environment, this
function can convert full-pitch Katakana as well.
Syntax
@Narrow( string )
Parameters
string
Text. The string that you want to convert to single byte characters.
Return value
returnstring
Usage
This function can be used in input translation formulas to convert the contents of a field to single byte
characters or in computed field formulas to save space for displaying the string.
Language cross-reference
StrConv function of LotusScript language
Examples: @Narrow
1. This input translation formula returns Tokyo as a half-pitch character, if the Location field contains
a full-pitch character expression of Tokyo.
@Narrow(Location)
2. This computed field formula returns New York as a half-pitch character to save space for
displaying the string.
@Narrow("New York")
@NewLine
Inserts a new line (carriage return) into a text string.
Syntax
@NewLine
Usage
On the Web, this function does not work in selection, form, or window title formulas.
In Lotus Notes, this function does not work in selection, hide-when, column, window title, form
formulas, or inside of @Prompt.
If you need to insert a carriage return inside an @Prompt formula, see @Char.
Language cross-reference
AddNewLine method of LotusScript NotesRichTextItem class
Examples: @NewLine
1. This returns
Hi There
"Hi"+@NewLine+"There"
2. This returns
Foster, Steven
in the EmpName field if the string in the LastName field is Foster, and the string in the field named
FirstName is Steven.
FIELD EmpName:= LastName + "," + @NewLine + FirstName;
3. This input translation formula uses @Newline to replace all occurrences of % with a carriage return.
If the description field contains Here we are now%Entertain us, the formula translates it to:
Here we are now Entertain us
@Implode(@Explode(description; "%"); @NewLine)
@No
Returns the number 0.
Return value
no
Usage
This function is equivalent to @False.
Examples: @No
1. This example returns 0.
@No
2. This example returns 1 if the value in the Cost field is greater than 100; otherwise returns 0.
@If(Cost>100;@Yes;@No)
@NoteID
The ID number of the current document.
Syntax
@NoteID
Return value
NT idnumber
Usage
This function does not work in forms or navigators.
Language cross-reference
NoteID property of LotusScript NotesDocument class
@Nothing
Use with an @Transform formula. Returns no list element (reducing the return list by one element). Not
valid in any other context.
Syntax
@Nothing
Usage
See @Transform for additional information and examples.
@Now
Returns the current timedate.
Syntax
@Now( flags ; serverNames )
Note: The flags and serverNames parameters are new with Release 6.
Parameters
flags
serverNames
Text or text list. Optional. A server name or a list of server names. This parameter applies when
[SERVERTIME] is specified.
Return value
now
Time-date or time-date list. The current time-date of the local computer, the server containing the current
database, or one or more specified servers. See the Usage section that follows.
Usage
@Now gets the time-date of the local computer in the following cases:
v No parameters are specified.
v [SERVERTIME] is specified, but the database is local and serverNames is not specified.
v [LOCALTIMEONERROR] is specified, serverNames is specified, and an error occurs getting the
time-date from a server.
@Now gets the time-date of the server containing the current database if [SERVERTIME] is specified and
serverNames is not specified.
@Now gets the time-date or time-dates of one or more specified servers if [SERVERTIME] and
serverNames are specified.
An error occurs if @Now cannot get the time from a server specified in serverNames and
[LOCALTIMEONERROR] is not specified.
The @Now function returns the current time with one hundredths of a second precision. However, if you
use @Now to specify the current time in a computed field, the hundredths of a second value is always
rounded up to the next second, which can result in the current time being one second fast. You can avoid
this by replacing @Now with the following formula:
timenow := @Now;
@Date(@Year(timeNow);@Month(timeNow);@Day(timeNow);@Hour(timeNow);@Minute(timeNow);@Sec(timeNow))
Language cross-reference
Now function of LotusScript language
Examples: @Now
1. This field value formula returns 01/21/96 7:30:45 AM at 7:30:45 A.M. on January 21, 1996.
@Now
2. This agent displays the times on the two servers named Snapper and Tornado.
@Prompt([Ok];
"Server time";
@Implode("Snapper" : "Tornado" + " " +
@Text(@Now([ServerTime] : [LocalTimeOnError];
"Snapper" : "Tornado")); @Char(13)))
@OptimizeMailAddress
Given a mail address, returns it with all unnecessary domains removed.
Syntax
@OptimizeMailAddress( address )
Parameters
address
Return value
optimizedAddress
Usage
All domains between two duplicate domains, including the duplicate domain, are removed.
Examples: @OptimizeMailAddress
1. This example returns username @ firstdomain @ thirdomain.
@OptimizeMailAddress ("username @firstdomain @secondomain @firstdomain @thirdomain")
2. This example returns username @ firstdomain @ secondomain.
@OptimizeMailAddress ("username @firstdomain @firstdomain @secondomain")
Syntax
@OrgDir
Return value
subdirectory name
String. The name of the subdirectory containing the data directory for the company with which the
current user is registered.
Usage
If the currently authenticated user is not registered in a hosted organization, is authenticated as an
anonymous user, or if the function is invoked in a non-xSP environment, Lotus Notes/Domino returns an
empty string ().
Examples: @OrgDir
If the full path name of the data directory subdirectory for a hosted organization called Acme is
C:\Lotus\Notes\Data\Acme, the following code opens a database on the same server that has the same
name as the current database, but that resides in the Acme organizations subdirectory. @OrgDir returns
Acme in the formula below.
@Command([FileOpenDatabase];@ServerName + ":" + @OrgDir + "\\" + @DbName[2])
@Password
Encodes a string.
Syntax
@Password( string )
Parameters
string
Return value
encodedString
Usage
@Password is especially useful in an input translation formula to protect a users password from being
seen by others.
Note: There is no way to decode the original string once it has been encoded by @Password.
Examples: @Password
1. This example returns (0449960361D30391DDA7747D537C32F8).
@Password("chocolate")
2. This example returns (EFFF7C4218F3CBD6D7B509CD2E021DD8).
@Password("vanilla")
3. This example returns (0449960361D30391DDA7747D537C32F8).
@Password("chocolate":"vanilla")
@PasswordQuality
Evaluates the return value of a Password data type field with a number.
Syntax
@PasswordQuality( field_name )
Parameters
field_name
Return value
passwordQuality
Number. A rating indicating the level of complexity of a password. A high number indicates a complex
password that is difficult to decipher.
Usage
This function is supported on the Web.
Language cross-reference
MinPasswordLength property of LotusScript NotesRegistration class
@Pi
Returns the constant value pi, accurate to fifteen decimal places. The value pi is the ratio of the
circumference of a circle to its diameter.
Syntax
@Pi
Return value
pi
Examples: @Pi
1. This formula returns the circumference of a circle with a radius that equals 5.
2 * @Pi * 5
2. This formula converts an angle from degrees to radians. One degree equals pi/180 radians. Thus an
angle of 360 degrees equals 2pi radians, 180 degrees equals pi radians, and so on.
( angle * @Pi ) / 180
3. Given the latitude of a particular location, you can find a locations distance from the equator. The
numeric field latitude holds the latitude in degrees. The numeric field distance computes the distance
from the equator using this formula.
First, latitude is converted to radians. Next, its multiplied by 6440, the approximate radius of the
earth in kilometers. This gives us the length of the arc from the equator to the given latitude.
Lotus Notes/Domino treats an empty numeric field as a text field, so the formula uses @If to check
for an empty latitude field.
@If( latitude = ""; 0; ( ( latitude * @Pi ) / 180 ) * 6440 )
@PickList
Displays a modal window that contains either:
v A view you specify from which the user can select one or more documents. @PickList returns a column
value from the selected document(s).
v A dialog box, displaying information from all available Domino Directories. The user can select one or
more person, group, server, room, or resource names, and @PickList returns those names.
Syntax
@PickList( [CUSTOM] : [SINGLE] ; server : file ; view ; title ; prompt ; column ; categoryname )
@PickList( [ROOM] )
@PickList( [RESOURCE] )
Parameters
[CUSTOM]
[NAME]
[ROOM]
[RESOURCE]
[FOLDERS]
Keyword. Returns a multi-select, text list of all folder names both in the database and from the desktop.
The following keywords can be combined with [Folders]:
[SINGLE]
[SHARED]
[PRIVATE]
Keyword. Optional. Limits selection to only private folders (both in the database and on the desktop).
[SHARED]:[PRIVATE]
[NODESKTOP]
server : file
Text list. The server is the name of the server where the database is. The file is the path and file name of
the database you want to open. Specify the name and location of the database using the appropriate
format for the operating system.
You can use a replica ID in place of a server and file name as the parameter following the [custom]
keyword only. The replica ID must be text and must include the colon between the two sets of eight hex
digits. For example:
@PickList([CUSTOM]; "852564A0:006B7872"; "By Category"; "Testing replica ID"; "Test prompt"; 3)
view
Text. The name of the view that you want to open in the database.
title
prompt
Text. The prompt that you want to appear inside the dialog box. Only one line of text is displayed.
Longer lines are truncated.
column
Number. A number indicating which column value you want @PickList to return. Use 1 to indicate the
first column, 2 to indicate the second column, and so on. Unlike @DbColumn and @DbLookup, @PickList
counts all columns, regardless of the types of formula they contain.
categoryname
Text. Optional. Displays the specified category in the view. The view should be categorized in order to
use this parameter.
Return value
columnValue
Text list. The value(s) in the specified column for the document(s) that the user selected.
Usage
This function is useful in button, manual agent, paste agent, form action, and view action formulas. It
does not work in column, selection, mail agent, scheduled agent, hide-when, window title, or form
formulas.
@PickList doesnt offer a NoCache option like @DbColumn and @DbLookup because lookup results are
never stored. Each time @PickList is executed, a new lookup is performed.
For a calendar view, @PickList displays two days starting with today, without time slots. The user can
click on the date picker button to navigate to other days.
@PickList can return no more than 64K bytes of data. Use the following equations to determine how
much of your data can be returned using @PickList.
Language cross-reference
PickListStrings method of LotusScript NotesUIWorkspace class
Examples: @PickList
1. This formula displays the Products view of PROD.NSF in a dialog box. If the user selects a Staple
remover and Stapler from the products view, the temporary variable choice gets assigned the
following text list: Staple remover; Stapler
choice:=@PickList( [CUSTOM] ; "" ; "Products" ; "Select a product" ; "Please
select the products you want to order" ; 1 );
2. This formula achieves the same result as the one above, but uses @DbName to display the Products
view of the current database.
choice:=@PickList( [CUSTOM] ; @DbName ; "Products" ; "Select a product" ; "Please
select the products you want to order" ; 1 );
3. This formula also displays the Products view of the current database, but returns the contents of the
second column in the view.
choice:=@PickList( [CUSTOM] ; @DbName ; "Products" ; "Select a product" ; "Please
select the products you want to order" ; 2 );
4. This formula is the same as above but limits the selection to a single document.
choice:=@PickList( [CUSTOM] : [SINGLE] ; @DbName ; "Products" ; "Select a product" ; "Please
select the products you want to order" ; 2 );
5. This formula opens the By Category view of the current database and displays only the items in the
Leather category.
choice:=@PickList( [CUSTOM] ; "" ; "By Category" ; "Select a product" ; "Please
select the products you want to order" ; 5; "Leather");
6. This formula displays the Names dialog box. The names of the people, groups, or servers that the
user selects are placed in the person field on the current document.
FIELD person:=person;
@SetField( "person"; @PickList( [NAME] ) )
@Platform
Returns the name of the currently running platform version of Lotus Notes/Domino.
Syntax
@Platform( [S PECIFIC ] )
Parameters
[S PECIFIC ]
Keyword. Optional. Returns more detailed information; for example, the version number in addition to
the name of the platform.
Return value
platform
When you use the [Specific] keyword, @Platform returns a text list containing the following items:
v PrimaryOSName
One of the platform names listed below:
v PrimaryOSVersionNumber
The current version number of the primary operating system. The number is specific; for example, 3.11.
For the UNIX platform, @Platform([SPECIFIC]) returns only the specific platform name, not the version
number.
v SecondaryOSName
The name of the secondary operating system. For example, MS-DOS is the secondary operating system
when Windows/16 runs on top of it. The values are the same as those for the primary operating
system. Most platforms dont have a secondary operating system.
v SecondaryOSVersionNum
The current version number of the secondary operating system.
Usage
When it is used in column, selection, or scheduled agent formulas, @Platform returns the current
platform where the database resides. If the database resides on a server, @Platform returns the server
platform; if the database resides locally, @Platform returns the workstation platform.
Your application may perform certain operations that are not available in all platform versions of Lotus
Notes/Domino (such as the DDErelated functions). Rather than receive an error, you could use
@Platform to determine whether or not to perform the operation.
You can use @Platform([Specific]) to distinguish between Windows 32 platforms (NT versus 95), and
between UNIX or OS/2 platforms.
This function returns the server platform only. Use @ClientType to distinguish between Web and
Notes/Domino users.
@PolicyIsFieldLocked
Indicates whether a field is locked by an administration policy and cannot be modified.
Syntax
@PolicyIsFieldLocked( fieldName )
Parameters
fieldName
Return value
flag
Number.
v Returns 1 (True) if the field is locked. For a list, all the fields must be locked.
v Returns 0 (False) if the field, or any field in a list, is not locked.
Usage
This function is intended for use in hide-when and Input Enabled formulas.
This function does not work in view column, view selection, or view action formulas.
A policy lock is indicated by the presence in the document of a computed field whose name is or begins
with $DPLocked and whose value is the name of the locked field.
Examples: @PolicyIsFieldLocked
This field hide-when formula hides the field if it is locked by an administration policy.
@PolicyIsFieldLocked(@ThisName)
@PostedCommand
Executes a Notes/Domino command. Most of the standard menu commands can be executed using
@PostedCommand. In addition, a number of specialized commands are available. In a formula, any
command invoked using @PostedCommand executes after the rest of the formula has been evaluated.
Syntax
@PostedCommand( [ command ] ; parameters )
See the specific @Command topic for details on parameters available for that command.
Usage
This function does not work in column, selection, hide-when, section editor, window title, field, or form
formulas, or in agents that run on a server. Its intended for use in toolbar button, hotspot, and action
formulas.
Note: If your formula will be executed in Notes Release 3, use @PostedCommand instead of @Command;
Notes Release 3 cannot execute an @Command formula constructed in Release 4 or later. If your
@command formulas constructed in Release 3 are compiled in Release 4 or later, Lotus Notes/Domino
automatically changes each occurrence of @Command to @PostedCommand.
@Power
Raises a number to the power of an exponent.
Syntax
@Power( base ; exponent )
Parameters
base
Number. The value that you want raised to exponent. May be positive or negative.
exponent
Return value
result
Language cross-reference
Exponentiation operator of LotusScript language
Examples: @Power
1. This example returns 8 (2 raised to the power of 3, or 23).
@Power(2;3)
2. This example returns 8 (-2 raised to the power of 3, or 23).
@Power(2;3)
3. This example returns 0.125 (2 raised to the power of 3, or 23).
@Power(2;3)
Syntax
@Prompt( [ style ] : [ NoSort ] ; title ; prompt ; defaultChoice ; choiceList ; filetype )
Parameters
[ style ]
Keyword. Required. Indicates the type of dialog box to display. May be any of the following:
[LocalBrowse]
[Ok]
[OkCancelCombo]
[OkCancelEdit]
[OkCancelEditCombo]
[OkCancelList]
[OkCancelListMult]
[Password]
[YesNo]
[YesNoCancel]
Include the square brackets ([ ]); these identify the style parameters as keywords. If no [NoSort] keyword
is provided, follow the style parameter with a semicolon (;).
[NoSort]
Keyword. Optional. Include this keyword if you want the members of choiceList to appear in the exact
order in which you enter them. If you omit this keyword, the members of choiceList are sorted
alphabetically.
title
Text. The text you want displayed in the dialog boxs title bar. Required for all styles, although you can
specify a null string with . The maximum number of characters you can include in a title is 65. Provide
a null string with the [ChooseDatabase] keyword; you cannot replace the default Choose Database title.
prompt
Text. The text you want displayed within the dialog box. Required for all styles, except LocalBrowse. If
you use a formula for prompt and that formula returns a list, only the first item in the list is displayed as
the prompt. To display the entire list, use @Implode. You can specify a field name to display the contents
of the field as the prompt, but the field must be a text field. If it is a number or datetime field, precede it
with @Text. @NewLine cannot be used in prompt. Use @Char(13) to insert a carriage return. The
maximum number of characters you can include in the text that displays is 255. Provide a null string for
the [ChooseDatabase] keyword; you cannot display custom text in the Choose Database dialog box.
defaultChoice
Text. The value that will be used as the default value for the users input. The input section of the dialog
box is primed with the value; the user can either accept it by clicking OK or replace it with another
value. Not applicable to dialog boxes of style [Ok], [YesNo], [YesNoCancel], [LocalBrowse], or [Password].
Required for all other styles. For [OkCancelListMult], you can specify multiple default values as a text list
item1:item2.
choiceList
filetype
Text. A value that specifies the types of files to display initially: 1 for NSF files only; 2 for NTF files
only; 3 for files of all type. Required only with style [LocalBrowse].
Return value
choice
v If the user enters a value, returns the value as text or a text list.
v If the user selects Yes, returns 1 (True).
v If the user selects No, returns 0 (False).
v If the user selects Cancel, formula evaluation stops. The exception is [YesNoCancel], which returns -1 if
the user selects Cancel.
v @Prompt([OkCancelEdit]) returns only the first 254 characters of the text entered.
Usage
Use @Prompt in field formula, toolbar button, manual agent, form action, and view action formulas. This
function does not work in column, selection, mail agent, or scheduled agent formulas, and has limited
usefulness in window title and form formulas.
Language cross-reference
InputBox function of LotusScript language
Examples: @Prompt
1. [Ok] displays an informational message; the user clicks OK to close the dialog box. Use this style
when you want to inform the user about something, without receiving anything back except an
acknowledgement.
@Prompt([Ok];"Reminder";"Dont forget to run backup tonight.")
2. [YesNo] displays a warning, and gives the user a chance to proceed or cancel the operation. If the
user selects Yes the numeric value 1 is returned. If the user selects No the numeric value 0 is
returned.
@Prompt([YesNo]; "Send memo?"; "This memo will be sent to everyone listed in the To, CC, and BCC fields.")
3. [YesNoCancel] also displays a warning, and gives the user a chance to select Yes, No, or Cancel. If
the user selects Cancel, the value -1 is returned.
result=@Prompt([YesNoCancel]; "Send memo?"; "This memo will be sent to everyone listed in the To, CC,
and BCC fields" )
4. [OkCancelEdit] prompts the user to enter his or her name, which is returned as a text string. The
name defaults to the current users Notes/Domino user name, which is calculated using
@UserName. If the user selects Cancel, Lotus Notes/Domino cancels the formula evaluation. Note
that @Prompt([OkCancelEdit]) returns only the first 254 characters of the text entered.
@Prompt([OkCancelEdit]; "Enter Your Name"; "Type your name in the box below."; @UserName)
@ProperCase
Converts the words in a string to propername capitalization: the first letter of each word becomes
uppercase, all others become lowercase.
Syntax
@ProperCase( string )
Return value
properString
Usage
A word is a consecutive set of characters with no spaces. Hyphenated words are considered two words,
as are words separated by any other punctuation except an apostrophe.
Language cross-reference
StrConv function of LotusScript language
Examples: @ProperCase
1. This example returns Every Child Loves Toys.
@ProperCase("every CHILD LOves toys")
2. This example returns 3Digit Code.
@ProperCase("3digit code")
3. This example returns Los Angeles if the string in the field named City contains the string los angeles,
Los Angeles, LOS ANGELES, los Angeles, or any other variation.
@ProperCase(City)
@Random
Generates a random number between 0 and 1, inclusive.
Syntax
@Random
Usage
To generate a random number between any two numbers x and y, use the formula
(
y
-
x
)*@Random +
x
Language cross-reference
Rnd function of LotusScript language
Examples: @Random
This formula generates a random number between 7 and 22, inclusive. For example, it might return 13.
15 * @Random + 7
Syntax
@RefreshECL( server : database ; name )
Parameters
server : database
Text list. The server location and file name of the Address Book. Omit server or specify it as (null) for
the local Notes/Domino directory.
name
Text. The name of the ECL. Specify (null) for the unnamed ECL.
Usage
You cannot use this function in Web applications.
Examples: @RefreshECL
This formula refreshes your personal workstation ECL from the administration ECL named Developers
in the Address Book on the server Marketing.
@RefreshECL("Marketing" : "names.nsf"; "Developers")
@RegQueryValue
Queries the Windows registry for a specified value.
Syntax
@RegQueryValue( keyName ; subKeyName ; valueName )
Parameters
keyName
subKeyName
String. The name of the subkey under keyName that you want to query.
valueName
Return value
string
The value associated with the value name specified in the valueName parameter.
Examples: @RegQueryValue
This example obtains the current registered Notes executable directory in Windows.
@RegQueryValue("HKEY_LOCAL_MACHINE"; "Software\\Lotus\\Notes\\5.0"; "Path")
REM
The REM reserved word allows you to add explanatory remarks (comments) to a formula. Quotation
marks or braces delimit the text of the remark.
Syntax
REM comments ;
REM { comments } ;
Usage
The backslash ( \ ) serves as an escape character in a remark. To embed quotation marks in a remark
delimited by quotation marks, precede each embedded quotation mark with a backslash. To embed a
right brace in a remark delimited by braces, precede each embedded right brace with a backslash. To
embed a backslash in a remark, type two backslashes.
A compiled formula does not distinguish between quotation marks and braces. When you open a design
element containing formulas, braces delimit all constants including those previously specified with
quotation marks. A backward slash prefixes a right brace previously specified in a remark delimited by
quotation marks.
If a comment doesnt fit on one line, add additional REM statements to complete the comment.
Language cross-reference
%Rem directive of LotusScript language
Examples: REM
1. This formula contains five lines of comments before the code.
@Repeat
Repeats a string a specified number of times.
Parameters
string
number
numberchars
Number. Optional. The maximum number of characters you want returned. @Repeat truncates the result
to this number.
Return value
repeatedString
Text. The string, repeated number times until numberchars(if specified) is reached.
Usage
The resultant string cannot be larger than 1,024 characters.
Language cross-reference
UString function of LotusScript language
Examples: @Repeat
1. This example returns HelloHelloHello.
@Repeat("Hello";3)
2. This example returns ByeBy.
@Repeat("Bye";2;5)
3. This example returns Great Month! Great Month! Great Month! in the Comments field if the amount
in the field named Sales is greater than or equal to 100,000; otherwise it returns the string Good
Month.
FIELD Comments:=@If(Sales>=100000;@Repeat("Great Month!";3);"Good Month");
Syntax
@Replace( sourcelist ; fromlist ; tolist )
Parameters
sourcelist
fromlist
Text list. A list containing the values that you want to replace.
tolist
Return value
replacedList
Text list. The sourcelist,with any values from fromlist replaced by the corresponding value in tolist. If none
of the values in fromlist matched the values in sourcelist, then sourcelistis returned unaltered.
Language cross-reference
Replace function of LotusScript language
Examples: @Replace
1. Both sourcelistand fromlist contain Orange, which is the first value in fromlist. The first value in
tolistreplaces Orange in sourcelist. No other matches were found, so the remainder of sourcelist is left
intact; the result is shown below:
@Replace("Red":"Orange":"Yellow":"Green";"Orange":"Blue";"Black":"Brown")
2. This formula looks at the Categories field in each document that it runs against. If one of the
keywords in a documents Categories field is To be assigned then that keyword is replaced with the
name stored in that documents AssignedTo field.
FIELD Categories:= @Trim(@Replace(Categories;
"To be assigned"; AssignedTo));
You have a database where you log service requests. Incoming requests are automatically categorized
as To be assigned by a mail/paste filter. Each day, you review the new (unassigned) service
requests, and assign them to technicians by entering the appropriate name in the AssignedTo field.
Once a request has been assigned, you want it to appear under that technicians name in the view,
instead of under To be assigned.
@ReplaceSubstring
Replaces specific words or phrases in a string with new words or phrases that you specify. Case sensitive.
Syntax
@ReplaceSubstring( sourceList ; fromList ; toList )
Parameters
sourceList
Text or text list. The string whose contents you want to modify.
fromList
Text or text list. A list containing the words or phrases that you want to replace.
toList
Return value
newSourceList
Text or text list. The sourceList, with any values from fromListreplaced by the corresponding value in
toList. If none of the values in fromListmatched the values in sourceList, then sourceListis returned
unaltered.
Usage
If more strings are specified in the fromList than the toList, the extra strings in fromListare replaced with
the last string in toList. Extra strings in toListare ignored. If no matches are found, @ReplaceSubstring
returns the unmodified sourceList.
If a list is specified for fromList, each subsequent list item is scanned against the resulting sourceList, with
prior list item substitutions performed.
For example:
@ReplaceSubstring("first";"first":"second";"second":"third")
returns third.
First, @ReplaceSubstring substitutes second for first from the first list item in fromList. The resulting
sourceListis now second. The function substitutes third for second from the second list item in
fromList.
Tip: Use @ReplaceSubString to remove carriage returns from text by replacing them with or .
Language cross-reference
Mid statement of LotusScript language
@ReplicaID
Returns the replica ID of the current database.
Syntax
@ReplicaID
Return value
title
Usage
The replica ID is a 16-character combination of letters and numbers that identifies a Notes database. Any
databases with the same replica ID are replicas of one another.
Language cross-reference
ReplicaID property of LotusScript NotesDatabase class
Examples: @ReplicaID
This agent mails the replica ID of the current database to the current user.
@MailSend(@UserName; ""; ""; "Replica ID"; @ReplicaID)
@Responses
Returns the number of responses (in the current view) to the document.
Syntax
@Responses
Return value
numResponses
Special text. The number of responses to the document. Special text cannot be converted to a number.
Language cross-reference
Responses property of LotusScript NotesDocument
Examples: @Responses
1. This example returns 5 if there are five responses to the document.
@Responses
2. This formula returns the string No one has responded to this document if there are no responses to
the current document; otherwise a blank is returned.
@If(@Responses=0; "No one has responded to this document"; " ")
@Return
Immediately stops the execution of a formula and returns the specified value. This is useful when you
only want the remainder of the formula to be executed only if certain conditions are True.
Syntax
@Return( value )
Parameters
value
The value you want returned. You can specify another @function such as @Error, or a text string such as
Formula stopped, or a Boolean value (True or False). If you dont want anything returned, use the null
string ().
Return value
result
Returns value.
Usage
@Return is most useful in field formulas, agents that run formulas, and toolbar buttons. Generally, you
use it with @If to determine whether to perform @Return or to perform one or more other statements.
Language cross-reference
End statement of LotusScript language
Examples: @Return
1. This formula displays a dialog box offering the user a Yes/No choice. If the user selects Yes, the next
document in the view is opened; if the user selects No, the formula stops and nothing more happens.
@Right
Returns the rightmost characters in the string. You can specify the number of rightmost characters you
want returned, or you can indicate that you want all the characters to the right of a specific substring.
Syntax
@Right( stringToSearch ; numberOfChars ) or @Right( stringToSearch ; subString )
Parameters
stringToSearch
numberOfChars
Number. The number of characters to return. If the number is 2, the last two characters of stringToSearch
are returned; if the number is 5, the last five characters are returned, and so on.
subString
Text. A substring of stringToSearch.@Right returns all of the characters to the right of subString. It finds
subString by searching stringToSearch from left to right.
Return value
resultString
Text. The rightmost characters in stringToSearch. The number of characters returned is determined by
either numberOfChars or subString. @Right returns if subString is not found in stringToSearch.
Language cross-reference
Right function of LotusScript language
@RightBack
Returns the rightmost characters in a string.
Syntax
@RightBack( stringToSearch ; numberOfChars )
Parameters
stringToSearch
numberOfChars
Number. Counting from left to right, the number of characters to skip. All the characters to the right of
that number are returned.
subString
Text. A substring of stringToSearch. @RightBack returns all the characters to the right of subString. It finds
subString by searching stringToSearch from right to left.
Return value
resultString
Text. The rightmost characters in stringToSearch. The number of characters returned is determined by
either numberOfChars or subString.
Language cross-reference
StrRightBack function of LotusScript language
Examples: @RightBack
1. This example returns nard Wallace.
@RightBack("Lennard Wallace";3)
2. This example returns a blank.
@RightBack("Lennard Wallace";"")
3. This example returns Wallace.
Note: @RightBack returns the string to the right of the last occurrence of the substring you are
searching for.
@Round
Rounds the designated number to the nearest whole number; if an additional number is specified, it is
used as the rounding factor.
Syntax
@Round( number ) @Round( number ; factor )
Parameters
number
factor
Number. Optional. The rounding factor to use. For example, if factor is 10, @Round rounds to the nearest
number that is a factor of 10. If you dont specify a factor, the number is rounded to the nearest whole
number.
Return value
roundedNumber
Number. The value of number, rounded to the specified factor or to the nearest whole number. If number is
a list, each number in the list is rounded to the specified factor or to the nearest whole number.
Usage
When using this function with a number list, the list concatenation operator takes precedence over any
other operators.
For more information, see List concatenation operator in the Formula Language Rules chapter.
Language cross-reference
Round function of LotusScript language
Examples: @Round
1. This example returns 2.
@Round(2.499)
2. This example returns 3.
@Round(2.5)
3. This example returns 2.
@Second
Extracts and returns the seconds value from the specified timedate.
Syntax
@Second( timedate )
Parameters
time-date
Time-date.
Return value
seconds
Number. The number of seconds in the second part of the time. Returns -1 if the time-date provided
contains only a date and not a time value.
Language cross-reference
Second function of LotusScript language
Examples: @Second
1. This example returns 45.
@Second([9:30:45])
2. This example returns 45 if the current time is 12:30:45 P.M.
@Second(@Now)
3. This example returns 45 as a text string if the contents of the field named Date is any timedate value
in which the number of seconds is 45.
@Text(@Second(Date))
SELECT
The SELECT reserved word defines criteria for the selection of documents in an agent that runs a
formula, in a view, or during replication. You use a SELECT statement before an expression to define the
set of documents that you want to change, see in a view, or replicate.
Syntax
SELECT formula ;
Using SELECT in the formula eliminates the need to go through the database to select the documents.
You can run the filter macro on all the documents in the database, and the SELECT statement performs
the selection process.
The word SELECT is automatically prepended to the view selection formula when the formula is saved.
Use SELECT @All to select all documents for an operation (for example, use it in the selection formula
for a view that displays all of the databases documents). @All should never be used without the SELECT
reserved word. If your formula contains @All by itself, Lotus Notes/Domino appends the SELECT @All
statement to your formula:
@All;
SELECT @All;
If you compare a field to a value (for example, Year > 1995) and the field is unavailable, the comparison
is false. However, you should check for fields that may not be present with @IsUnavailable.
This reserved word does not work in column, hide-when, section editor, window title, hotspot, field,
form, or form action formulas.
Language cross-reference
SelectionFormula property of LotusScript NotesView class
Examples: SELECT
1. You want to change the contents of the Status field in several documents to Closed. However, you do
not want to change the Status field of any document that contains the value Unsigned Contracts in
the Categories field.
To make the desired change, you write and run an agent that runs a formula. When you write the
formula, you specify the documents that you want Lotus Notes/Domino to scan to make the change.
By adding a SELECT statement to the formula, you can further limit the documents that Lotus
Notes/Domino looks at when you run the agent.
SELECT Categories != "Unsigned Contracts";
FIELD Status := "Closed";
2. This replication formula limits replication to documents that contain a Year field whose value is
greater than 1995.
SELECT @IsAvailable(Year) & Year > 1995
3. This replication formula limits replication to documents that do not contain a Year field or whose Year
field is greater than 1995.
SELECT !@IsAvailable(Year) | Year > 1995
Syntax
@Select( number ; values )
Parameters
number
values
Any number of values, separated by semicolons. A value may be a number, text, time-date, or a number
list, text list, or time-date list.
Examples: @Select
1. This example returns 3.
@Select(3;1;2;3)
2. This example returns 3.
@Select(5;1;2;3)
3. This example returns Apr;May;Jun.
@Select(2;"Jan":"Feb":"Mar";"Apr":"May":"Jun";
"Jul":"August":"Sep";"Oct":"Nov":"Dec")
4. This example returns San Diego;Sydney;New York;Amsterdam if the field named TrainingCenters
contains these city names.
@Select(3;SalesOffices;ServiceOffices;TrainingCenters)
@ServerAccess
Checks if a specified user has a specified administrative access level to a server.
Syntax
@ServerAccess( [ access ] ; userName ; serverName )
Parameters
[ access ]
Keyword. Supply one of the following keywords to represent the access level you want to check for:
[ACCESS]
[CREATEDATABASE]
[CREATETEMPLATE]
[DATABASEACCESS]
User has administrative access to the server, which enables him or her to perform all the tasks that
adminstrators with Access level access can perform, except users with DatabaseAccess cannot issue
remote console commands.
[FULLACCESS]
User has full administrative access to the server and is given manager access to all databases hosted by
the server, regardless of the databases ACL settings.
[REMOTEACCESS]
[RESTRICTEDSYSTEMACCESS]
User can issue only those operating system commands that are listed as Restricted System commands.
[SYSTEMACCESS]
[TRACKMESSAGE]
User can track email messages, but cannot view the contents of the Subject field of mail memos.
[TRACKMESSAGESUBJECT]
User can track email messages and can view the contents of the Subject field of mail memos.
[VIEWONLYACCESS]
User can issue a subset of remote console commands that supply information about the server; they
cannot execute remote commands that affect the servers operation.
These access levels are set by the server administrator on the Security tab of the Current Server
Document in the Server settings found on the Configuration tab of the Domino Administrator client.
userName
Text; not case-sensitive. Hierarchical name of the user whose access you want to check, enclosed in
quotation marks. If you supply a short name, this function returns zero. You can use @UserName to
supply the name of the current user to @ServerName.
serverName
Return value
flag
Boolean.
v 1 (True) indicates that the specified user has the specified access
v 0 (False) indicates that the specified user does not have the specified access
Examples: @ServerAccess
1. This code, when added as the default value of a field in a database on the ocean/bay server, returns 1
if Luisa Albright is listed as having standard administrative access to the ocean/bay server in the
server document for ocean/bay.
@ServerAccess([ACCESS];"Luisa Albright/bay";"ocean/bay")
2. This code, when added as the default value of a field in a Local database that has ocean/bay selected
as its Administrative server on the Advanced tab of the databases ACL dialog box, returns 1 if Luisa
Albright has standard administrative access to the ocean/bay server.
@ServerAccess([ACCESS];"Luisa Albright/bay")
3. This code, when added as the default value of a field in a database running on the ocean/bay server,
returns 1 if the current user has full access to the ocean/bay server and all of its databases.
@ServerAccess([FULLACCESS];@UserName)
4. This code, when added as the default value of a field, returns 0 because it does not recognize the
short user name.
@ServerAccess([ACCESS];"Luisa Albright";"ocean/bay")
5. This code, when added as the default value of a field, returns 0 if Luisa Albright does not have full
access to the ocean/bay server and all of its databases.
@ServerAccess([FULLACCESS];"Luisa Albright/bay";"ocean/bay")
@ServerName
Returns the name of the server containing the current database. When the database is local, returns the
user name.
Syntax
@ServerName
Return value
serverName
Text. The name of the server containing the current database or the user name if triggered from a local
database.
Examples: @ServerName
1. This formula, when added to a hotspot button on a form running on the acme/central server, displays
a Server name message box that reads CN=acme/O=central.
@Prompt([OK]; "Server name"; @ServerName)
2. This formula, when added to an action button on a form running on the acme/central server, displays
a Server name message box that reads acme.
@Prompt([OK]; "Server name"; @Name([CN]; @ServerName))
3. When this code is added to a client toolbar button it displays CN=Mary Anne Admin/O=central if
the button is triggered by Mary Anne while she is working with a form from a local database.
@Prompt([OK]; "Server name"; @ServerName)
@Set
Assigns a value to a temporary variable for use within a formula.
Syntax
@Set( variableName ; value )
Parameters
variableName
value
Usage
With Release 6, you no longer need to declare the variable receiving the assignment prior to setting its
value with @Set. For R5 and earlier clients, declare the variable by assigning it a null value at the
beginning of the formula:
TemporaryVariable:=
Language cross-reference
Set statement of LotusScript language
Examples: @Set
This formula determines whether the FirstName field is blank. If so, it sets the variable FullName to the
concatenation of the Title field with the LastName field, as in Ms. Tsen. If the FirstName field contains
a value, the variable FullName is instead set to the concatenation of the FirstName with the LastName, as
in Mary Tsen.
@SetDocField
Given the unique ID of a document, sets the value of a specific field on that document. The document
must reside in the current database.
Syntax
@SetDocField( documentUNID ; fieldName ; newValue )
Parameters
documentUNID
Text. The unique ID of a document. @DocumentUniqueID specifies the unique ID of the current
document. To specify the unique ID of the parent document, use $Ref as the first parameter. $Ref is a
special field on a response document that contains the unique ID of the parent document.
fieldName
Text. The name of a field on the document, enclosed in quotation marks. If you store the field name in a
variable, omit the quotation marks here.
newValue
Text or text list; number or number list; time-date or time-date range. The value you want to give to the
field.
Usage
This function does not work in column or selection formulas. @SetDocField is particularly useful in field,
button, and agent formulas.
Note: Starting with Release 6, you can use @SetDocField to set the value of a field in the current
document, not just in other documents in the same database.
Language cross-reference
FieldSetText method of LotusScript NotesUIDocument class
Examples: @SetDocField
1. This formula, if placed on a button in a response form, changes the Subject of the parent document to
More people are commuting by bicycle. $Ref is a special field on a response document that contains
the unique ID of the parent document.
@SetDocField($Ref; "Subject"; "More people are commuting by bicycle")
2. This button formula changes the value of the name field in the current document to Joseph Riley:
@SetDocField(@DocumentUniqueID;"name";"Joseph Riley")
@SetEnvironment
Sets an environment variable stored in the users notes.ini file (Windows, OS/2, and UNIX) or Notes
Preferences file (Macintosh).
Syntax
@SetEnvironment( variableName ; value )
Parameters
variableName
Text. The name of the environment variable, enclosed in quotation marks. If you enter a text list for the
variableName, then every variable named in that list receives the specified value. If you store the field
name in a variable, omit the quotation marks here.
value
Text. The value you want to give to variableName. If you use a text list for value, only the first value in the
list is used; the rest are ignored.
Usage
Use @SetEnvironment when you want to set an environment variable from within another @function
(such as @If or @Do). To set the environment variable outside of an @function, use @Environment or the
ENVIRONMENT keyword.
@SetEnvironment cannot be used in column or selection formulas. Some formulas, such as scheduled
agents, are run on the server instead of the users workstation. In this case, the environment variables
affected are the servers environment variables, not the workstations.
You cannot use this function in Web applications. However, in Web applications, you can use predefined
field names to gather information about the Web users environment by requesting Common Gateway
Interface (CGI) environment variables.
This function prepends a dollar sign ($) to the variable name when it stores the variable in the notes.ini
(or Notes Preference) file. Use the SetEnvironmentVar method of the LotusScript NotesSession class or the
setEnvironmentVar method of the Java Session class if you want to create a variable without the
prepended dollar sign.
@SetField
Assigns a value to a field stored within a document (use @Set for temporary variables). This is similar to
using the FIELD keyword, except that @SetField can be used within another @function. If the field does
not exist, this command creates it and applies the specified value to it.
Syntax
@SetField( fieldName ; value )
Parameters
fieldName
The name of the field whose value you want to set, enclosed in quotation marks.
value
The value you want to give to fieldName. The value must be the same data type as the field; for example,
if the field is numeric, the value must be a number.
Usage
This function is most useful in agents, hotspot buttons, actions, and toolbar buttons. It does not work in
column, selection, hide-when, window title, or form formulas.
With Release 6, you no longer need to declare the field receiving the assignment prior to setting its value
with @SetField. For R5 or earlier clients, declare the field at the beginning of the formula, as follows:
FIELD Fieldname:=Fieldname;
The field that @SetField creates and assigns the specified value to if the specified field does not exist in
the document is not visible to the user. You can remove a field added to a form this way using the
@DeleteField function.
Language cross-reference
FieldSetText method of LotusScript NotesUIDocument class
Examples: @SetField
1. This formula checks the value of the Priority field; if the Priority is Low or Medium, the Status field is
set to Closed; otherwise, the Status is set to Open. Before @SetField is encountered in the formula, the
Status field is declared using the FIELD keyword.
FIELD Status:=Status;
@If(Priority="Low"|Priority="Medium";@SetField("Status";"Closed");
@SetField("Status";"Open"))
2. This code, when used in a view action button, deletes fields x_1 through x_20 in the selected
document.
@SetHTTPHeader
In a Web application, sets the value of HTTP headers in the response being generated by the server for
the browser client.
Syntax
@SetHTTPHeader( responseHeader ; value )
Parameters
responseHeader
value
Text, number, or date. A value for the field. Dates are converted to RFC 1123 format. An empty string ()
removes the header and its value from the HTTP response.
Return value
successOrFailure
Number. @True, or one (1), if the HTTP response header was successfully updated; @False, or zero (0),
otherwise.
Usage
@SetHTTPHeader is useful in formulas that run in the context of a browser; the Notes client always
returns @False, or zero (0), for this formula.
Language cross-reference
Headers property of LotusScript NotesMIMEEntity class
Examples: @SetHTTPHeader
This form action sets the value of the response-header field named Set-Cookie to
SHOP_CART_ID=4646. As a result, the browser client registers a cookie for the server using this name
and value.
@SetHTTPHeader("Set-Cookie"; "SHOP_CART_ID=4646")
@SetProfileField
Sets the value of a field in a profile document or creates a profile document.
Syntax
@SetProfileField( profilename ; fieldname ; value ; uniqueKey )
Parameters
profilename
Text. The name of the profile document that contains the field you want to access. If no profile document
exists by this name, Lotus Notes/Domino creates one.
fieldname
value
uniqueKey
Return value
value
Usage
Use this function to create a profile document in a Web application. The EditProfile @command does not
work on the Web. If no document exists with the name specified as the first parameter of this function,
Lotus Notes/Domino creates a profile document with that name. Use @GetProfileField to access data
from the profile document.
Language cross-reference
EditProfile method of LotusScript NotesUIWorkspace class
Examples: @SetProfileField
1. This example sets the contents of the Profile Categories field of the Interest Profile document to
the name of the current platform.
@SetTargetFrame
Allows you to specify a target frame when opening a view, page, or frameset, or when composing or
editing a document.
Syntax
@SetTargetFrame( targetframe )
Parameters
targetframe
Text. The name of the frame that a view, page, frameset, or document should open into.
Usage
Use @SetTargetFrame before opening or refreshing the view, page, or frameset, or before composing or
editing a document. The following @commands use the frame specified in the @SetTargetFrame:
v @Command([Compose])
v @Command([EditDocument])
v @Command([OpenFrameset])
v @Command([OpenPage])
v @Command([OpenView])
v @Command([RefreshFrame])
If you specify the newinstance parameter for @Command([OpenView]), the @SetTargetFrame function is
ignored.
If you do not specify a viewName for@Command([OpenView]), then the last view is the one that opens in
the specified targetframe of @SetTargetFrame.
Language cross-reference
SetTargetFrame method of LotusScript NotesUIWorkspace class
Examples: @SetTargetFrame
Consider 2 framesets -- one that contains Frame A and Frame B and another frameset nested within
Frame B that contains Frame C and Frame D.
This example opens the view My View in Frame A of the first frameset.
@SetTargetFrame("Frame A");
@Command([OpenView]; "My View");
This example is code in a button on Frame C of the nested frameset. It opens the form My form in
Frame D of the same frameset:
@SetTargetFrame("Frame D");
@Command([Compose]; "My form");
@SetViewInfo
In Standard Outline views, filters a view to display only documents from a specified category. In
Calendar views, filters a view to display only documents that contain a specified string in a specified
column.
Syntax
In a Standard Outline view:
In a Calendar view:
Parameters
[SETVIEWFILTER]
Keyword. Required. Indicates you want to qualify the documents that display in a view.
filterString
Text. Serves as the key to determine which documents display in a view. If this string is present in the
column specified in columnName, includes the document in the view.
columnName
Text. The programmatic name of a column. The column specified here must contain the filterString for the
document to display in the view.
isCategory
Number. Boolean value. Required in a Standard Outline view; not for use in Calendar views. 1 indicates
that the column in the columnName value is a category. 0 indicates that it is not.
exactMatch
Usage
This @function is useful if you want to filter the documents in a view to display only a subgroup that
contains specific data.
Examples: @SetViewInfo
1. This formula, when added to a hotspot button in a form, opens the Customers Standard Outline view,
which is categorized by companyName. The view contains documents for people from several
companies, but filters the view to display only those documents for individuals who work at the
Acme Corp.
@Command([OpenView];"Customers");
@SetViewInfo([SETVIEWFILTER];"Acme Corp.";"companyName";1)
2. This code, when added to a the Sort action button in a Standard Outline view, filters the contents of
the current view to display only those documents that have empolyeeName fields that contain the
current users name. The view is categorized by employeeName.
@SetViewInfo([SETVIEWFILTER];@Name([CN];@UserName);"employeeName";1)
3. This code, used in the View by Room action button in the Reservations template (resrc60.ntf), updates
the Calendar view to display only calendar entries that specify as their resourceName value the
resource chosen by the user from a pick list. $20 is the programmatic name of the Resource column,
whose value is determined by the resourceName field.
choice:=@PickList([CUSTOM] : [SINGLE]; @DbName; "Resources";"View by Room or Resource";"Select the room or
resource whose calendar you want to see:"; 1);
@SetViewInfo([SETVIEWFILTER];choice;"$20";0)
@Sign
Indicates whether a number is positive, negative, or zero.
Syntax
@Sign( signedNumber )
Parameters
signedNumber
Return value
sign
Language cross-reference
Sgn function of LotusScript language
418 Prgramming Guide, Volume 1: Overview and Formula Language
Examples: @Sign
This formula sets the result field to Profit! if the earnings field is greater than the expenses field, Loss!
if expenses are greater than earnings, and Break even if they are equal.
field result:=result;
difference:=earnings - expenses;
r:=@If( ( @Sign( difference ) = 1); "Profit!"; ( @Sign( difference ) = -1 ); "Loss!"; "Break even" );
@SetField( "result"; r )
@Sin
Given an angle in radians, returns the sine of the angle. In a right triangle, the sine of an acute angle is
the ratio of the length of its opposite side to the length of the hypotenuse.
Syntax
@Sin( angle )
Parameters
angle
Return value
sine
Language cross-reference
Sin function of LotusScript language
Examples: @Sin
1. This formula returns 1, the sine of the angle Pi/2 (90 degrees).
@Sin( @Pi/2 )
2. You have a triangle ABC. You know the value of angle A in radians, and the lengths of sides a and b.
This formula finds angle B, in radians. This formula is a version of the law of sines, which states that
for any triangle ABC, (sin A / a) = (sin B / b) = (sin C / c).
@ASin( ( sideB *( @Sin( angleA ) ) ) / sideA )
@Sort
Sorts a list.
Syntax
@Sort( list ; [ order ]; customSortExpression )
Parameters
list
Text, number, or time-date list. The values to be sorted. Any alternate data types are returned unchanged.
Keyword. Optional. You can use the following keywords to specify the order of the sort:
[ACCENTSENSITIVE]
[ACCENTINSENSITIVE]
[ASCENDING]
[CASESENSITIVE]
[CASEINSENSITIVE]
[CUSTOMSORT]
[DESCENDING]
[PITCHSENSITIVE]
[PITCHINSENSITIVE]
Separate multiple order keywords with a colon(:). By default, the following keywords automatically
format the sort order:
[ASCENDING]:[CASESENSITIVE]:[ACCENTSENSITIVE]:[PITCHSENSITIVE].
You can override a default sort order keyword by specifying its opposite keyword. For example, to
override [ASCENDING], specify [DESCENDING] in the @Sort function. If conflicting keywords are
passed, the last one in the list affects the sort order.
customSortExpression
Formula. Required when the [CUSTOMSORT] keyword is specified. A formula that uses the temporary
variables $A and $B to compare the values of elements in the list two at a time. If $A is greater than $B,
the expression returns @True. If $B is greater than $A, the expression returns @False.
An error is produced if the customSortExpression produces a data type other than a number.
Return value
list
Usage
The ascending, case-, and accent-sensitive sort sequence for the English character set is as follows: the
numbers 0-9, the alphabetic characters aA-zZ, the apostrophe, the dash, and the remaining special
characters. Pitch-sensitivity affects double-byte languages.
Note: The case sensitive sort only matters when terms are identical except for case. In that instance, the
lower case is sorted first. For example, cat, Cat, CAT. If terms are not identical except for case, they are
sorted without regard to case.
If you set Unicode standard sorting as the sorting option, you cannot select the following keywords or
combinations:
v [PITCHINSENSITIVE]
420 Prgramming Guide, Volume 1: Overview and Formula Language
v [CASESENSITIVE]:[ACCENTINSENSITIVE]
You specify Unicode standard sorting by setting the notes.ini variable $CollationType to @UCA, or by
selecting the Unicode standard sorting checkbox that displays in the following dialog boxes:
v Sorting dialog box that displays when you choose File - Preferences - User Preferences - International -
Sorting from the main menu
v Database Properties box*
v Design Document Properties box*
*The Unicode option is disabled in the Database and Design Document Properties boxes until you select
a default sort order.
A date-time value with a wildcard time (no time specified) equals all date-time values for the same date.
For example, the following dates are considered equal:
These values are sorted in random order and may be ordered differently with each sort if multiple sorts
are performed on them.
Examples: @Sort
These examples are translation formulas. Assume that the initial value of the field is a list containing:
New Boston, Albany, new york, San Francisco.
1. This formula returns: Albany, New Boston, new york, San Francisco.
@Sort(@ThisValue)
2. Same as above.
@Sort(@ThisValue; [ASCENDING])
3. This formula returns: San Francisco, New Boston, new york, and Albany.
@Sort(@ThisValue; [DESCENDING])
4. This formula returns: Albany, New Boston, New York, San Francisco.
@Sort(@ProperCase(@ThisValue); [ASCENDING])
These examples are used as the default values for form fields.
1. This formula returns 1009;85;79 if the Price column (the 5th column in the Gear view) contains the
prices 79, 85, and 1009 for three entries in the Ski Pants category:
@Sort(@DbLookup("";"Server/Name/Notes":"Ski\\Clothing.nsf";"Gear";"Ski Pants";5);[DESCENDING])
2. This formula returns the contents of the movies field in order from the shortest title to the longest; it
returns ET;casablanca;The Great Escape when the movies field contains casablanca:The Great
Escape:ET:
@Sort(movies;[CASESENSITIVE]:[CUSTOMSORT];@If(@Length($A) < @Length($B);-1;@Length($A) > @Length($B);1;0))
Note that the custom sort keyword overrides the case-sensitivity keyword.
3. This formula returns the following passwords in order from the strongest to the weakest:
HE5ll+o;Hel$lo;hello, when the pswd1 field contains Hello, pswd2 field contains HE5ll+o, and the
pswd3 field contains Hel$lo.
@Sort(pswd1:pswd2:pswd3;[CUSTOMSORT];@If(@PasswordQuality($A) <
@PasswordQuality($B);1;@PasswordQuality($A) > @PasswordQuality($B);-1;0))
4. This formula returns: cat, Cat, CAT, dog when the animals field contains CAT, Cat, dog, cat.
@Sort(animals;[CASESENSITIVE])
Syntax
@Soundex( string )
Parameters
string
Return value
code
Text. The Soundex code. You cannot convert it to any other data type.
Usage
This function is used almost exclusively by the Domino Directory. You will rarely use this function.
Examples: @Soundex
1. This example returns F430.
@Soundex("field")
2. This example returns P430.
@Soundex("phield")
@Sqrt
Given a number, returns its positive square root.
Syntax
@Sqrt( number )
Parameters
number
Number. The number whose square root you want to find. The number must be positive, otherwise @Sqrt
returns an error.
Language cross-reference
Sqr function of LotusScript language
Examples: @Sqrt
This example returns 4.
@Sqrt( 16 )
Syntax
@StatusBar( statusBarText )
Return value
statusBarText
Text or text list. The text of the status bar message. A list produces one message per element.
Usage
This @function works only in the Notes client.
Examples: @StatusBar
1. This onLoad/Postopen event writes a message to the status bar.
@StatusBar("Loaded \"Form A\" in \"" + @Subset(@DbName; -1) + "\"")
2. This onLoad/Postopen event writes two messages to the status bar.
@StatusBar("Loaded \"Form A\"" :
("Database is \"" + @Subset(@DbName; -1) + "\""))
@Subset
Searches a list from left to right and returns the number values you specify. If you specify a negative
number, @Subset searches the list from right to left, but the result is ordered as from the beginning of the
list.
Syntax
@Subset( list ; number )
Parameters
list
Text list, number list, or time-date list. The list whose subset you want.
number
Number. The number of values from list that you want. Specifying zero (0) returns the error, The second
argument to @Subset must not be zero.
Return value
subsetList
Text list, number list, or time-date list. The list, containing the number of values you specified.
Examples: @Subset
1. This example returns New Orleans;London.
@Subset("New Orleans":"London":"Frankfurt":"Tokyo";2)
@Success
Returns 1 (True). Use this function with @If in field validation formulas to indicate that the value entered
satisfies the validation criteria.
Syntax
@Success
Return value
true
Usage
Use @Success in input validation formulas for editable fields.
Examples: @Success
This example returns 1 and allows the document to be saved when the value in the field Price is less
than 100. This indicates that acceptable data was entered when used in an input validation formula.
@If(Price<100;@Success;@Failure("Price too large"))
@Sum
Adds a set of numbers or number lists.
Syntax
@Sum( numbers )
Parameters
numbers
Numbers or number lists. As many numbers or number lists as you want to sum.
Return value
result
Number. The sum of all the numbers, including members of number lists.
Usage
Make sure the fields you send as parameters contain a number value -- Notes/Domino interprets empty
number fields as the null string.
Examples: @Sum
1. This example returns 3.
@Sum( 1 : 2 )
2. This example returns 11.
@Sum( (-1) : 2 ; (-10) : 20 )
3. This example sets the Total field to 50 if numPersons is a number field containing 5; 10; 15; 20.
@SetField("Total";@Sum(numPersons))
4. This example looks at the Transactions view in the current database, whose first column contains
number values indicating the amount of a transaction. The formula sums the transactions and places
the total in the result field on the current document.
FIELD result:=result;
r:=@DbColumn("":""; ""; "Transactions"; 1 );
@SetField( "result"; @Sum( r ) )
5. This example displays a view in a dialog box. The first column in the view contains a product name,
the second contains its price. After the user selects one or more products in the dialog box, the
formula displays the total cost of the selected items.
amounts:=@PickList( [Custom]; @DbName ; "Products"; "Choose products"; "Please select the products you
want to order"; 2 );
total:=@Sum( @TextToNumber( amounts ) );
@Prompt([Ok]; "Total"; "The total cost of these products is " + @Text(total))
@Tan
Given an angle in radians, returns the tangent of the angle. In a right triangle the tangent of an acute
angle is the ratio of the length of the opposite side to the length of the adjacent side.
Syntax
@Tan( angle )
Parameters
angle
Return value
tangent
Language cross-reference
Tan function in LotusScript language
Examples: @Tan
This example returns 1.
@Tan( @Pi/4 )
Syntax
@TemplateVersion
Return value
versionNumber
Usage
This @function applies when Inherit design from master template is checked on the Design tab of the
Database Properties. The template version number can be seen there.
@Text
Converts any value to a text string.
Syntax
@Text( value ; formatstring )
Parameters
value
Number, time-date, rich text, or text. The value you want to convert to text.
format-string
Text. Optional. Up to four format-strings (see table below). These determine how the text is returned. If
the valueis already a text data type, the formatstring is ignored.
Return value
textValue
Text. The value you specified, converted to text. If you used any format-strings,they are applied.
Symbol Meaning
D0 Month, day and year
D1 Month and day, year if it is not the current year
Symbol Meaning
G General format (significant digits only)
F Fixed format (set number of decimal places)
S Scientific format (E notation)
C Currency format (two decimal places)
, Punctuated at thousands (using U.S. format)
% Percentage format
() Parentheses around negative numbers
number Number of digits of precision
Usage
Once a number value is converted to text, you will not be able to use the number for arithmetic
calculations.
Rich text conversion loses attachments and all formatting except tabs and spaces. When rich text is
converted in a document, the document must be saved before the conversion becomes visible.
Rich text conversion does not work in column formulas. Use @Abstract to convert the contents of a rich
text field to plain text. Then reference the plain text field in the view. For example, if you add the
following code to a hidden computed field called plainText, you can then set the default value of the
view column to plainText to display the contents of the RTField:
@Abstract([TextOnly];15360;"";"RTField")
Use caution if using @Text to convert numbers or dates in a column. In databases hosted by a server, the
numbers and dates always display using the format settings of the hosting servers operating system.
Also, if the date or number format settings of either the client accessing the database or server hosting
the database change, you may need to entirely rebuild the view.
Examples: @Text
1. This example returns 123.45.
@Text(123.45)
2. This example returns $800.00 if the value in the Sales field is 800.
@Text(Sales;"C,2")
3. This example returns 8.00E+02.
@Text(800;"S")
4. This example returns 04/11/93 10:43 AM.
@Text(@Now)
5. This example returns 04/11.
@Text(@Now;"D1S0")
6. This example returns 10:43:30 AM.
@Text(@Now;"D1S1")
7. This example returns 04/93 10:43 AM.
@Text(@Now;"D3T1")
8. This example returns the rich-text Body field stripped of attachments and formatting.
@Text(Body)
9. To convert a number date (in the ShipDate field) into a written date, you can use the following code.
If ShipDate contains [08/31/2002], the result is August 31, 2002.
@If( @IsTime(ShipDate);
@Text(@Select(@Month(ShipDate); "January"; "February"; "March"; "April"; "May"; "June"; "July";
"August"; "September"; "October"; "November"; "December")) + " " +
@Text(@Day(ShipDate)) + ", " + @Text(@Year(ShipDate));
"No date given")
@TextToNumber
Converts a text string to a number, where possible.
Syntax
@TextToNumber( string )
Parameters
string
Text. The string you want to convert to a number. If the string contains both numbers and letters, it must
begin with a number to be converted properly. For example, the string 12ABC converts to 12, but
ABC12 produces an error.
Usage
This function is useful for converting a number in a text field to a number that can be used for
computation in a number field.
You cant use @TextToNumber to convert special text (such as that returned by @DocChildren or
@DocDescendants) to a number.
@TextToNumber returns an error If you try to pass anything besides a string into it.
Language cross-reference
Val function of LotusScript language
Examples: @TextToNumber
1. This example returns 123 as a number.
@TextToNumber("123")
2. This example returns @ERROR if the contents of the field named Cost cannot be converted to a
number.
@TextToNumber(Cost)
@TextToTime
Converts a text string to a timedate value, where possible.
Syntax
@TextToTime( string )
Parameters
string
Return value
time-date
Today, Tomorrow, and Yesterday are the only legal strings to use to represent relative dates. The
formula @TextToTime(Next week) returns a blank because the text string Next week cannot be
converted to a timedate value.
@TextToTime returns an error If you try to pass anything besides a string into it, including a time-date
value.
Language cross-reference
DateValue function of LotusScript language
Examples: @TextToTime
1. This example returns 8/10/90 2:40:00 AM.
@TextToTime("8/10/90 2:40")
2. This example returns Today.
@TextToTime("Today")
3. This example sets the value of the result field (a time-date field that allows multiple values) to the
date range 04/16/96 - 08/18/96.
FIELD result:=result;
@SetField( "result" ; @TextToTime( "04/16/96-08/18/96" ) )
@ThisName
Returns the name of the current field.
Syntax
@ThisName
Return value
name
Usage
This @function returns null outside a field formula.
This @function is useful in writing portable code. Use @ThisName to construct references to other fields
(for example, in @GetField) that have similar names.
Language cross-reference
CurrentField property of LotusScript NotesUIDocument class
@ThisValue
Returns the value of the current field.
Syntax
@ThisValue
Return value
value
Usage
This @function returns null outside a field formula.
This @function is useful in writing portable code. Use @ThisValue instead of the name of the current
field.
Language cross-reference
FieldGetText method of LotusScript NotesUIDocument class
Examples: @ThisValue
1. This translation formula replaces all spaces with underscores in the current field.
@ReplaceSubstring(@ThisValue; " "; "_")
2. This input validation formula for a listbox field checks whether the user selected more than one list
option and asks them to if they have not:
@If((@ThisValue != "") & (@Elements(@ThisValue) = 1);@Failure("You must select more than
one choice");@Success)
@Time
Translates numbers for the various components of time and date; then returns the timedate value.
Parameters
year
month
day
hour
Number. The number of hours you want to appear in the resulting time.
minute
Number. The number of minutes you want to appear in the resulting time.
second
Number. The number of seconds you want to appear in the resulting time.
time-date
Time-date. For a timedate value such as @Now or [10/31/93 12:00:00], @Time removes the date portion
of the value, leaving only the time.
Return value
truncatedTimeDate
Time-date. The time corresponding to the parameters you sent to @Time, minus any date components if
the parameter is time-date.
Language cross-reference
CDat function of LotusScript language
Examples: @Time
1. This example returns 4/11/51 11:50:30 PM.
@Time(1951;04;11;23;50;30)
2. This example returns 09:19:24 AM at 9:19:24 A.M on any day.
@Time(@Now)
3. This example returns 09:19:24 AM if 9:19:24 A.M is the time the document was created.
@Time(@Created)
Syntax
@TimeMerge( date ; time ; timeZone )
Parameters
date
Time-date value. The date you want to include in the new date-time value.
time
Time-date value. The time you want to include in the new date-time value.
timeZone
String. Optional. The canonical time zone value you want to apply to the new date-time value. You can
use a Time zone field to create this value.
Return value
Time-date
A new time-date value made up of the date, time, and zone supplied as function parameters.
Examples: @TimeMerge
1. This code, when added to a hostpot button, displays 02/23/2002 05:45:00 AM in the Merged date
dialog box if the field date contains 02/23/02 and the field time contains 17:45:00.
@Prompt([OK];"Merged date";@Text(@TimeMerge(date;time)))
2. This code, when added to a form action, displays 02/23/2002 05:45:00 AM in the Merged date dialog
box if the field date contains 02/23/02 02:30:00 and the field time contains 03/23/03 05:45:00.
@Prompt([OK];"Merged date";@Text(@TimeMerge(date;time)))
3. This code, when added to a hotspot button, displays 07/04/2002 08:30:00 PM in the Merged date
dialog box if the field date contains 07/04/02, the field time contains 13:30:00, and the field zone
contains Z=11$DO=0$ZX=1$ZN=Samoa (which displays as GMT-11:00). The hour is adjusted to reflect
the specified time zone.
@Prompt([OK];"Merged date";@Text(@TimeMerge(date;time;zone)))
@TimeToTextInZone
Converts a time-date value to a text string, incorporating time zone information.
Syntax
@TimeToTextInZone( timeDate ; timeZone ; formatString )
Parameters
timeDate
Time-date value.
Canonical time zone value. You can derive a time zone value using a Lotus Notes Time zone field.
formatString
You can include up to three specifiers, but only one that begins with D, one that begins with T, and one
that begins with S.
Return value
string
Examples: @TimeToTextInZone
1. This code, when used in an action button on a form, applies the zone information of GMT-00:00 that a
user selects from the list in the There Time zone field to the time-date of 02/26/2002 03:19 PM EST
that results from an @Now formula in the Here Date/Time field. The Time there message box that
appears displays 02/26/2002 08:19:00 PM.
@Prompt([OK];"Time there";@TimeToTextInZone(Here;There))
2. This code, when added as a Column Value formula, displays 11:06 AM Today in the view column if
the Here field contains 02/26/2002 03:06 PM EST, the There field contains Z=9$DO=1$DL=4 1 1 10-1
1$ZX=3$ZN=Alaskan (which displays as GMT -09:00 Alaska), and the current date is 02/26/2002.
@TimeToTextInZone(Here;There;"D2T1S3")
@TimeZoneToText
Converts a canonical time zone value to a human-readable text string.
Syntax
@TimeZoneToText( timeZone ; formatString )
Canonical time zone value. Use a Lotus Notes Time zone field to create a time zone value.
formatString
GMT-08:00
A Alias for local time zone. For example, if the zone is the same as the zone in
which the system is running, returns:
Local time
Return value
string
The time-date value converted to a string. If you do not include a format specifier, a long time zone label
is returned. For example:
Usage
This function is useful for displaying the contents of a Time zone field in a view. If you do not use this
function, a Time zone field value displays in the view with a format similar to the following:
Also use this function with the @GetCurrentTimeZone function to translate the time zone value it returns
into a readable string.
Examples: @TimeZoneToText
1. This code, when added as the Column Value formula for a view, displays the contents of the Time
zone field named Zone as GMT-07:00 if the Zone field has the value Z=7$DO=0$ZX=6$ZN=US
Mountain (which is selected in the Time zone field as GMT-07:00 Arizona).
@TimeZoneToText(Zone;"S")
2. This code, when added as the Column Value formula for a view and accessed from a system running
in the EST time zone, displays a document that has (GMT 00:00) Greenwich Mean Time: Dublin,
Edinburgh, Lisbon, London selected in its Zone Time zone field as and a document that has
(GMT-05:00) Eastern Time (US & Canada) selected in its Zone field as Local time.
@TimeZoneToText(Zone;"SA")
@Today
Returns todays date.
Syntax
@Today
Usage
This function is identical to the formula @Date(@Now). It is usually used in default value formulas to
automatically enter the current date.
Using @Today in column or selection formulas may impact the efficiency of your application. It also
causes the view refresh indicator to display constantly.
In a field formula, Lotus Notes/Domino takes the value for @Today from the client computers clock.
Language cross-reference
Now function of LotusScript language
Examples: @Today
1. This example returns 02/19/93 if today is February 19, 1993.
@Today
2. This example sets the field named ReceivedDate to todays date.
FIELD ReceivedDate:=@Today
@Tomorrow
Returns the timedate value that corresponds to tomorrows date.
Syntax
@Tomorrow
Return value
tomorrow
Usage
Using @Tomorrow in column or selection formulas may impact the efficiency of your application. It also
causes the view refresh indicator to display constantly.
In a field formula, Notes/Domino takes the value for @Tomorrow from the clock in the client computer.
Examples: @Tomorrow
1. This example returns 4/26/93 if today is April 25, 1993.
@Tomorrow
2. This example sets the field named AnswerBack to tomorrows date.
FIELD AnswerBack:=@Tomorrow
@ToNumber
Converts a value with a data type of text or number to a number value.
Syntax
@ToNumber( value )
Parameters
value
Text or number. A value having any other data type returns the error, The value cannot be converted to
a Number.
Return value
number
Usage
This function is useful for ensuring that a value has a number data type before using it in functions that
require numbers as parameters.
Language cross-reference
Val function of LotusScript language
@ToTime
Converts a value with a data type of text or time to a date-time value.
Syntax
@ToTime( value )
Parameters
value
Text or time. A value having any other data type returns the error, The value cannot be converted to a
Number.
Return value
time
Usage
This function is useful for ensuring that a value has a time data type before using it in functions that
require time values as parameters.
Language cross-reference
DateValue function of LotusScript language
Examples: @ToTime
1. This code, when added to a field, converts the text value in the date field containing 08/29/01
into a time value and adds two days to the date. This function returns 08/31/01.
@Adjust(@ToTime(date);0;0;2;0;0;0)
2. This example, when added to an action button, displays the date two days after the date selected by a
user in the request date-time field.
@Prompt([Ok];"Delivery";@Text(@Adjust(@ToTime(holiday);0;0;2;0;0;0)))
@Transform
Applies a formula to each element of a list and returns the results in a list.
Parameters
list
variableName
Text. The name of a variable. Use this variable in the formula to refer to the list element being acted
upon.
formula
Valid formula that evaluates to a result. The remainder of @Transform after the second parameter is the
formula that is applied to each element of the input list. The formula must return a value.
Return value
list
Text, number, or time-date. The result of the transformation on the input list. The first value returned by
the formula determines the data type of the list. Subsequent return values must be of the same type.
Usage
An iteration of the formula can return a list, which adds multiple values to the return list.
If an iteration of the formula returns @Nothing, no element is added to the return list.
Language cross-reference
ForAll statement of LotusScript language
Examples: @Transform
The following examples are translation formulas that transform the elements of the numeric multi-value
field OriginalList. Assume that OriginalList contains the values 4, -4, and 16.
1. This formula returns a 3-element list whose values are 2, -2, and 4.
@Transform(OriginalList; "x";
@If(x >= 0; @Sqrt(x); -@Sqrt(@Abs(x))))
2. This formula returns the same as above. However, if OriginalList is null, this formula returns null
rather than an error.
@If(OriginalList = @Nothing; @Nothing;
@Transform(OriginalList; "x";
@If(x >= 0; @Sqrt(x); -@Sqrt(@Abs(x)))))
3. This formula returns a 2-element list whose values are 2 and 4.
@If(OriginalList = @Nothing; @Nothing;
@Transform(OriginalList; "x";
@If(x >= 0; @Sqrt(x); @Nothing)))
4. This formula, when used in a hotspot button creates a field called originalCorrected that adds an
asterisk to the beginning of each element in the original text list if it does not already have one.
FIELD originalCorrected := @Transform(original;"var";
@Trim
Removes leading, trailing, and redundant spaces from a text string, or from each element of a text list.
Syntax
@Trim( string )
Parameters
string
Return value
trimmedString
Usage
If a text string is all spaces, @Trim returns an empty string (length of 0). If an element of a text list is all
spaces, @Trim removes the element. If all elements of a text list are all spaces, @Trim returns an empty
string.
Language cross-reference
Trim function of LotusScript language
Examples: @Trim
1. This example returns ROBERT SMITH.
@Trim(@UpperCase("Robert Smith "))
2. This example returns ROBERT SMITH.
@UpperCase(@Trim(" Robert Smith"))
3. This example returns Just a quick reminder, if the original Topic field is Just a quick reminder.
@Trim(Topic)
4. This example returns Seattle;Toronto;Santiago;USA;Canada;Chile if the list of values contained in the
City field consists of Seattle, Toronto, Santiago; the StateOrProvince field contains no values; and the
Country field contains the list of values USA, Canada, Chile.
@Trim(City:StateOrProvince:Country)
5. This example returns 45 if the content of the field Date is 8/29/89 16:30:45.
@Trim(@Text(@Second(Date)))
@True
Returns the number 1. This function is equivalent to @Yes.
Syntax
@True
Language cross-reference
Built-in constants of LotusScript language
Examples: @True
1. This example returns 1.
@True
2. This example returns 1 if the value in the Dept field is greater than 100.
@If(Dept>100;@True;@False)
@Unavailable
Deletes the value of an editable field.
Syntax
FIELD fieldName := @Unavailable
Usage
This function works in agent, view action, and toolbar button formulas.
If the field has a default value, the default value is reinstated after this function deletes the current value.
Do not use this function to test to see if a field is unavailable. Use @IsUnavailable instead.
Language cross-reference
RemoveItem method of LotusScript NotesDocument class
Examples: @Unavailable
This formula creates a field named NewDate and sets it to todays date, then removes the field named
OldDate from the document.
FIELD NewDate:=@Today
FIELD OldDate:=@Unavailable;
Syntax
@UndeleteDocument
Usage
This @function can be used in toolbar button, hotspot, action, and agent formulas.
To allow soft -- that is, delayed -- deletions, go to the Advanced tab of database properties, check Allow
soft deletions, and specify an integer value for Soft delete expire time in hours. Soft-deleted documents
appear to be deleted but are held in the database for the specified number of hours before actual
deletion.
To see the soft-deleted documents, create a view of type Shared, contains deleted documents. To restore
a soft-deleted document, run @UndeleteDocument on it before the Soft delete expire time in hours
expires.
Examples: @UndeleteDocument
This is the formula for an action in a view of type Shared, contains deleted documents. The user can go
to this view, see the documents that are soft-deleted, and run this action on selected documents to restore
them. The database must Allow soft deletions and specify Soft delete expire time in hours.
@UndeleteDocument
@Unique
Without a parameter, returns a random, unique text value. With a parameter, removes duplicate values
from a text list by returning only the first occurrence of each member of the list.
Syntax
@Unique @Unique( textlist )
Parameters
textlist
Return value
Without a parameter:
uniqueValue
With a parameter:
uniqueList
Language cross-reference
ArrayUnique function of LotusScript language
Examples: @Unique
1. This example returns red; green; blue.
@Unique("red":"green":"blue":"green":"red")
2. This example returns red; green; blue; Green.
@Unique("red":"green":"blue":"Green":"red")
@UpdateFormulaContext
Updates the context of a formula to the Notes client window currently being accessed by the code. For
example, if the code accesses a new form called Response by using @Command([Compose]:Response,
@UpdateFormulaContext switches the context of the formula to this new form. Any subsequent functions
in the code execute in the context of the Response document, not the current document.
Syntax
@UpdateFormulaContext
Usage
You can use @UpdateFormulaContext to extract values from or set values in external documents. You can
even access document- and database-specific information using functions such as @DbName, @DbTitle,
@Created, @DocumentUniqueID, @GetDocField, @GetField, @GetProfileDocument.
This function is only valid in the Notes client; it is not supported in Web applications.
@UpdateFormulaContext is only valid in formulas that interact with the user, such as in agents that have
no target documents, events, toolbar buttons, hotspot buttons, and actions. It does not work in formulas
in which @commands cannot be used.
Examples: @UpdateFormulaContext
1. The following code, when used in a view action, creates a response document to the currently
selected document then populates its fname and lname fields with the values of the fname and lname
fields in the current document:
tempfname := fname;
templname := lname;
@Command([Compose];"Response");
@UpdateFormulaContext;
FIELD fname := tempfname;
FIELD lname := templname
2. The following code, when used in a view action that contains documents that have the fields
CreatedDate, which displays the documents creation date and nextCreated, an editable text field,
opens the previous document in the view and adds the creation date of the current document into its
nextCreated field:
tempDate := @GetDocField(@DocumentUniqueID;"CreatedDate");
@Command([NavPrev]);
@UpperCase
Converts the lowercase letters in the specified string to uppercase.
Syntax
@UpperCase( string )
Parameters
string
Return value
uppercaseString
Usage
This function is useful when you want to search for a particular value and cannot predict whether it will
appear in lowercase, uppercase, or a combination of the two. You can also use it as an input translation
formula to convert a fields contents to uppercase.
Language cross-reference
UCase function of LotusScript language
Examples: @UpperCase
1. This example returns ROBERT T. SMITH.
@UpperCase("Robert T. Smith")
2. This example returns MA if the State field contains ma, Ma, or MA.
@UpperCase(State)
3. This example returns FLETCHER if William Fletcher is the name associated with the current User
ID. @UpperCase is used in conjunction with @Right to find and convert only the users last name.
@UpperCase(@Right(@UserName;" "))
If the user id is a hierarchical id, the following code returns FLETCHER:
@UpperCase(@Right(@Name([CN]; @UserName); " "))
@URLDecode
Decodes a URL string into regular text.
Syntax
@URLDecode( decodeType ; token )
Text. The type of encoding you want to use to translate the token. You can specify either a string
argument or a MIME character set.
String arguments:
v Domino -- Decodes the token using the standard character set used by the Lotus Domino Web server.
This keyword is equivalent to the UTF-8 MIME character set.
v Platform -- Decodes the token using the current systems native character set.
Decodes the hexadecimal digits that represent the code value into octets, then converts the specified
character sets into LBMCS. The supported MIME character sets are:
v UTF-8 -- UCS(Universal Character Set) Transformation Format 8. An ASCII-compatible multi-byte
Unicode and UCS encoding.
v ISO-8859-1 -- The ISOs (International Standards Organization) 8-bit, single-byte-coded graphic
character set for European languages.
v Shift_JIS -- The character set for the Japanese language.
token
Return value
String
Examples: @URLDecode
1. This code, when used as the default value for a field, decodes the URL-formatted string in the encode
field. It returns Employee/My Database if the encode field contains
Employee%2FMy%20Database.nsf.
@URLDecode("Domino";encode)
@URLEncode
Encodes a string into a URL-safe format.
Syntax
@URLEncode( encodingFormat ; token )
Parameters
encodingFormat
Text. The type of encoding you want to use to translate the token. You can specify either a string
argument or a MIME character set.
String arguments:
v Domino -- Encodes the token in the standard character set used by the Lotus Domino Web server.
This keyword is equivalent to the UTF-8 MIME character set.
Converts non-ASCII characters into the specified character set and encodes the characters into %XX
format, where XX is a hexadecimal digit representing the encoded value. Some examples include:
v UTF-8 -- UCS(Universal Character Set) Transformation Format 8. An ASCII-compatible multi-byte
Unicode and UCS encoding.
v ISO-8859-1 -- The ISOs (International Standards Organization) 8-bit, single-byte-coded graphic
character set for European languages.
v Shift_JIS -- The character set for the Japanese language.
token
Return value
encodedURLString
Text or text list. Returns the URL string(s) encoded in the specified encoding format.
Usage
Do not use @URLEncode to encode an entire URL string. For example,
@URLEncode(Domino;http://www.ibm.com/) returns http%3A%2Fwww.ibm.com%2F, which
would not link successfully to the desired website.
Examples: @URLEncode
1. This formula returns By%20Date as the encoded URL.
@URLEncode("Domino";"By Date")
2. This formula returns Support%20%E0%20la%20client%E8le as the encoded URL.
@URLEncode("ISO-8859-1";"Support la clientle")
3. This formula returns Support%20%C3A0%20la%20client%C3%A8le as the encoded URL.
@URLEncode("UTF-8";"Support la clientle")
@URLGetHeader
Returns specific Hypertext Transfer Protocol (HTTP) header information from the Uniform Resource
Locator (URL). A URL is a text string used for identifying and addressing a Web page.
Syntax
@URLGetHeader( urlstring; headerstring; webusername; webpassword; proxywebusername; proxywebpassword )
Parameters
urlstring
Text. The URL for the Web page you want to open, for example, http://www.acme.com/.
headerstring
Enter a header string to return the desired URL header value. The acceptable header strings are
documented in the HTTP specification (available at locations on the Internet, such as
http://www.w3.org/) and are subject to change based on updated versions of the specification.
446 Prgramming Guide, Volume 1: Overview and Formula Language
webusername$
Text. Optional. Some Internet servers require you to obtain a user name and password before you can
access their pages. This parameter allows you to enter the user name that you previously obtained from
the authenticated Internet server.
webpassword$
Text. Optional. Some Internet servers require you to obtain a user name and password before you can
access their pages. This parameter allows you to enter the password that you previously obtained from
the authenticated Internet server.
proxywebusername$
Text. Optional. Some proxy servers require that you specify a user name in order to connect through
them. This parameter allows you to enter the user name for the proxy server. See your administrator for
the username required by the proxy.
proxywebpassword$
Text. Optional. Some proxy servers require that you specify a password in order to connect through them.
This parameter allows you to enter the user name for the proxy server. See your administrator for the
password required by the proxy.
Return value
headervaluestring
Text. Returns the header value that you requested. If a null value is returned, the header value that you
requested was not found in the header of the Web page.
Usage
The @URLGetHeader function should only be used in the context of either the Server Web Navigator or
Personal Web Navigator database.
Examples: @URLGetHeader
1. This example returns the last date that the www.acme.com Web page was modified.
@URLGetHeader ("http://www.acme.com/"; "Last-modified")
2. This example returns the name of the Web server software where the www.acme.com Web page
resides.
@URLGetHeader ("http://www.acme.com/"; "Server")
@URLHistory
Used for navigating, saving, and reloading a Uniform Resource Locator (URL) history list. The URL
history list keeps track of all the Web pages you have visited. The history list is used for the Next and
Previous buttons and for the Web Tours.
Syntax
@URLHistory( [ command ] )
Usage
The @URLHistory function works from the Notes/Domino workstation only and should only be used
with either the Server Web Navigator or Personal Web Navigator database.
Examples: @URLHistory
Below are examples of each command you want to specify.
[NEXT]
This example moves to the next URL in the history list.
@URLHistory([NEXT])
[PREV]
This example moves to the previous URL in the history list.
@URLHistory([PREV])
[SHOW]
This example displays the History dialog box.
@URLHistory([SHOW])
[SAVE]
This example saves the history list into a new Web Tour document that a user can reload later to follow
that history.
@URLHistory([SAVE])
[RELOAD]
This example reloads the history list from the Web Tour document.
@URLHistory([RELOAD])
@URLOpen
Retrieves a World Wide Web page specified by its URL.
@URLOpen( urlstring )
Parameters
urlstring
Text. Optional. The URL for the Web page you want to open, for example, http://www.acme.com/. This
parameter may also include comma-separated arguments to be passed by Domino to the javascript
window.open command.
[ reloadflag ]
Keyword. Optional.
RELOADIFMODIFIED. Reloads the page only if it has been modified on its Internet server.
[URLLIST]
Keyword. Optional. Web pages can contain URL links to other Web pages. This keyword specifies that
the Web Navigator should save the URLs in a field called URLLinksn in the Notes/Domino document.
(The Web Navigator creates a new URLLinksn field each time the field size reaches 64K. For example, the
first URLLinks field would be URLLinks1, the second would be URLLinks2, and so on.)
If you save the URLs, you can use them in agents; for example, you could create an agent that opens
Web pages in the Web Navigator database and then loads all the Web pages saved in each of the
URLLinksn field(s).
CAUTION:
Saving URLs in the URLLinksn field(s) may affect performance.
[RELOAD] : [URLLIST]
Keywords. Optional. Specify both keywords to force a reload of the Web page and save the URLs in the
URLLinksn field in the Notes/Domino document.
Text. Optional. Enter the MIME character set (for example, ISO-2022-JP for Japanese or ISO-8859-1 for
United States) that you want the Web Navigator to use when processing the Web page. Only use this
parameter when the Web Navigator detects the MIME character set of the URL contents incorrectly.
webusername
Text. Optional. Some Internet servers require you to obtain a user name before you can access their pages.
This parameter allows you to enter the user name that you previously obtained from the Internet server.
webpassword
Text. Optional. Some Internet servers require you to obtain a password before you can access their pages.
This parameter allows you to enter the password that you previously obtained from the Internet server.
proxywebusername
Text. Optional. Some proxy servers require that you specify a user name in order to connect through
them. This parameter allows you to enter the user name for the proxy server. See your administrator for
the user name required by the proxy.
proxywebpassword
Text. Optional. Some proxy servers require that you specify a password in order to connect through them.
This parameter allows you to enter the password for the proxy server. See your administrator for the
password required by the proxy.
Usage
The @URLOpen function works from both the Notes/Domino workstation and server.
The user name and password parameters work only with the Notes Web Navigator. Other browsers
always prompt for authentication.
For use on the server, you need to specify at least one parameter with the function; using the function
without any parameters will attempt to display the URL Open dialog box which cannot be done from the
server. If you want to use any of the parameters that follow the Reload and URLList keywords without
specifying values for either of the keywords, enter a zero (0) in place of the keyword value(s). For
example, @URLOpen(http://www.ibm.com;0;myusername;mypassword).
When a Notes browser triggers the @URLOpen function, it displays the retrieved Web page in a new
window. When the @URLOpen function is used on a form or page that is accessed by a non-Notes
browser, Domino generates a javascript window.open command with the following syntax:
window.open( [sURL] [, sName] [, sFeatures] [, bReplace])
To display the retrieved Web page in a new window, pass the values for sName and sFeatures (if desired)
as comma-separated arguments within the urlstring. For example,
@URLOpen(http://www.ibm.com,NEW). Be sure to use double quotes at the beginning and end of
the urlstring parameter, and single quotes before and after each comma separating the arguments to be
passed to window.open. Do not include any spaces.
To open another design element from the current Notes database in a Web application, use the
@WebDbName function to properly encode the database name.
Language cross-reference
URLOpen method of LotusScript NotesUIWorkspace class
Examples: @URLOpen
1. This example displays the URL Open dialog box that allows a user to enter the URL.
@URLOpen
2. This example opens the www.acme.com Web page from the database if it is found there. If the page is
not found in the database, it is retrieved from the Web, loaded into the database, and then opened.
@URLOpen("http://www.acme.com/")
3. This example retrieves the www.acme.com Web page from the Web, loads it into the database, and
then opens it.
@URLOpen("http://www.acme.com/"; 1)
4. The following code, when added to an action on the Purchasing Web application form, opens the
CustomerInfo Notes form, which resides in the same database:
@URLOpen(@WebDbName + "/CustomerInfo?OpenForm")
5. The following code, in a document viewed from the Web, will open the www.acme.com Web page in
the same window (_self) as that document.
@URLOpen("http://www.acme.com")
6. The following code, in a document viewed from the Web, will open the www.acme.com Web page in
a new window (_blank). Note that the window will not have any sFeatures assigned by previous
javascript commands.
@URLOpen("http://www.acme.com,_blank")
7. The following code, in a document viewed from the Web, will open the www.acme.com Web page in
a new window (_blank). All sFeatures will be inherited from the calling window.
@URLOpen("http://www.acme.com,_blank,")
8. The following code, in a document viewed from the Web, will open the www.acme.com Web page in
a new window (NEW). The window will not inherit any sFeatures.
@URLOpen("http://www.acme.com,NEW")
9. In a document viewed from the Web, clicking on the following hyperlink will open a new window
(mywindow) displaying the www.yahoo.com Web page.
<a href="javascript: mywin = window.open(http://www.yahoo.com,mywindow);mywin.focus()">yahoo</a>
The following code will open the www.acme.com Web page in the mywindow window. All sFeatures
will be inherited from the mywindow calling window.
@URLOpen("http://www.acme.com,mywindow,")
@UrlQueryString
In a Web application, returns the current URL command and parameters, or the value of one of the
parameters.
Parameters
parameterName
Return value
query
Usage
@UrlQueryString is useful in formulas that run in the context of a browser.
Examples: @UrlQueryString
For these examples, the URL command is:
http://www.acme.com/marketing.nsf?OpenForm&ID=986574&Category=Golf
1. This example:
@UrlQueryString
returns the list:
v OpenForm
v ID=986574
v Category=Golf
2. This example:
@UrlQueryString("Category")
returns the text:
v Golf
@UserAccess
Given a server and file name, indicates the current users level of access to the database.
Syntax
@UserAccess( server : file ; [ accessPrivilege ] )
Text. The name of the server. Use an empty string () to indicate the local computer.
file
Text. The path and file name of the database. Specify the databases path and file name using the
appropriate format for the operating system.
[ accessPrivilege ]
Keyword. Optional. Specify one of the following keywords to return a users access level or test for a
specific database privilege, instead of returning a list containing all of the users access information:
v [ACCESSLEVEL] returns a number from 1 to 6 that indicates the users access level to the database.
The following return 1 (True) if the user has the specified privilege and 0 (False) if the user does not.
These privileges are assigned in the Access Control List for the database.
v [CREATEDOCUMENTS]
v [DELETEDOCUMENTS]
v [CREATEPERSONALAGENTS]
v [CREATEPERSONALFOLDERSANDVIEWS]
v [CREATELOTUSSCRIPTJAVAAGENTS]
v [CREATESHAREDFOLDERSANDVIEWS]
v [READPUBLICDOCUMENTS]
v [WRITEPUBLICDOCUMENTS]
v [REPLICATEORCOPYDOCUMENTS]
Return value
If you specify one or more keywords, returns a text value or a text list containing the following values:
v The [AccessLevel] keyword returns a value of 1 through 6.
v The other keywords return a value of 1 or 0.
If you specify no keywords, returns a text list of values for the following keywords:
v [AccessLevel] : [CreateDocuments] : [DeleteDocuments] : [CreatePersonalAgents] :
[CreatePersonalFoldersAndViews] : [CreateSharedFoldersAndViews] : [CreateLotusScriptJavaAgents] :
[ReadPublicDocuments] : [WritePublicDocuments]
@UserAccess does not test for access to the ReplicateOrCopyDocuments privilege by default.
Tip: If the multi-value separator for the field containing the formula is a semicolon, the values in the
returned text list are separated by semicolons instead of colons.
This function does not work in column or selection formulas, or in agents that run on a server (mail and
scheduled agents). Hence it does not work with the Evaluate statement.
Language cross-reference
QueryAccess method of LotusScript NotesDatabase class
Examples: @UserAccess
1. This formula returns the text list 3: 1: 1: 1: 1: 0 if the user has Author access, permission to create
documents, delete documents, create private agents, create personal views and folders, but does not
have permission to create shared views and folders in the NUN.NSF database in the DISCUSS
directory on server Gaborone.
@UserAccess( "Gaborone" : "discuss\\nun.nsf" )
2. This formula, when added to a form action button, creates a new document using the MyOpinion
form if the current user has the privilege to create documents in the current (nun.nsf) database.
@If(@UserAccess( "" : "discuss\\nun.nsf" ; [CREATEDOCUMENTS]) = "1";@Command([Compose];"MyOpinion");@Prompt([OK];
"Access denied";"Sorry, you do not have permission to create documents in this database."))
3. This formula returns the text list 6: 1: 1: 1: 1: 1: 1: 1: 1 if the user has Manager access and permission
to create and delete documents, create private agents, create personal and shared views and folders,
create LotusScript and/or Java agents, read and write public documents in the current database. The
text list displays as 6; 1; 1; 1; 1; 1; 1; 1; 1 if the multi-value separator for the field containing this
formula is a semicolon.
@UserAccess( @DbName )
@UserName
Returns the current user name.
If the user name is hierarchical, @UserName returns it in canonical format (including the CN, OU, O, and
C identifiers). To return the name in abbreviated format (omitting those identifiers), use @V3UserName.
Notes
v If you used @UserName in Release 3, it is automatically converted to @V3UserName in Release 4 or
later to preserve the functionality of your formulas. If you change those formulas to use @UserName,
be sure to recompile them under Release 4 or later. If you use @UserName in Release 4 or later, a
database created in Release 3 will not recognize the formula until you upgrade that database. If the
formula will be evaluated in Release 3, use @V3UserName.
v With Release 5, @UserName returns the alternate name as well as the primary name which is
associated with the ID.
Syntax
@UserName ( index )
Number. Optional. Indicating the index of user names. 0 is for primary name and 1 is for the alternate
name. If this parameter is omitted, @UserName returns the primary name.
Return value
name
Usage
When a formula runs on a server, the agent signer is considered the current user. Using @UserName on a
local database or in a private view in a server-based database returns the users name. You should not
use @UserName in a public view, doing so produces unpredictable results. Also, if the field that you are
referencing changes, you will get unpredictable results because the index has to be rebuilt to
accommodate the new information.
One use for @UserName is to display only those documents relevant to the current user. For example,
your Service Request database could use @UserName in the private view named Assignments to display
each technicians assignments, weeding out everyone elses:
SELECT @UserName=AssignedTo
However, the user can still design a different private view that retrieves all documents, so dont depend
on @UserName as a security mechanism.
For an alternative way to display only documents relevant to the current user, see To show a single
category in an embedded view.
If you are using Release 5 and have an alternate name as well as a primary name, it is best to store the
alternate name in the document as author information when using the extended feature of @UserName.
Language cross-reference
UserName property of LotusScript NotesSession class
Examples: @UserName
1. This example returns CN=Robert T. Katsushima/OU=JPN/O=Acme if this is the name associated
with the current user ID.
@UserName(0)
2. This example returns Robert T. Katsushima.
@Name([CN];@UserName)
3. This example returns CN=Rob Katsushima/OU=JPN/P=Acme if this is the first alternate name
associated with the current user ID.
@UserName(1)
4. This example returns Fletcher if William Fletcher is the name associated with the current User ID.
@Right(@UserName;" ")
5. This example returns FLETCHER if William Fletcher is the name associated with the current User ID.
@UserNameLanguage
Returns language tags associated with the user ID.
Syntax
@UserNameLanguage( index )
Parameters
index
Number. Indicates the index of user names. 0 is for primary name and 1 is for alternate name. Numbers
greater than 1 are not used but reserved for future use.
Return value
namelanguage
Text. Language tag for the alternate user name. If the user does not have the alternate name,
@UserNameLanguage returns an empty string (). Also, this function returns an empty string for the
primary name.
Usage
The alternate name is expected to be used for a users native language name.
Generally the native language name contains non-ASCII characters and cannot be displayed correctly
without some proper fonts. The return value from @UsernameLanguage is used as reference of the native
language.
@UserNameLanguage can be used as a default value formula to store the authors alternate language tag
in their document as well as their primary name and alternate name. While referring to the language tag,
the Domino application can switch the display name on the document between the primary name and
the alternate name.
Language cross-reference
Language property of LotusScript NotesName class
@UserNamesList
For a database on a server or a local database with Enforce a consistent Access Control List across all
replicas in effect, @UserNamesList returns a text list containing the following information for the current
user:
v Common name
v All hierarchical names (fully distinguished) that include the user name; for example, CN=My
Name/OU=My Org Unit/O=My Org, plus */OU=My Org Unit/O=My Org, */O=My Org, and *
v Any roles associated with the user in the ACL
v All groups to which the user belongs (only if the database is on a server)
Syntax
@UserNamesList
Return value
names
Text list. Each list item is a name or role as specified above. Returns an empty string () if the current
database is local and Enforce a consistent Access Control List across all replicas is not in effect, and the
database is not replicated with the server database at least once.
Usage
This function does not work in column, selection, mail agent, or scheduled agent formulas.
Choose File - Database - Access Control, Advanced to set Enforce a consistent Access Control List across
all replicas.
Examples: @UserNamesList
This subform formula selects a different subform depending on whether the user is a member of the
Marketing team or not. This formula works if the database containing it is on a server.
@If(@IsMember("Marketing Team"; @UserNamesList);
"Marketing Head"; "Generic Head")
@UserPrivileges
Returns a text list of the current users privileges. This function returns only the position of the privilege
in the privilege list, not the name of the privilege.
Return value
privileges
Usage
This function does not work in scheduled agent formulas.
Language cross-reference
NotesACLEntry class
ACLEntry class
Examples: @UserPrivileges
1. A database has five privileges. User Mary Tsen has been assigned Privileges 2 and 3. This example
returns the text list 2:3 (which displays as 2;3 if the multi-value separator for the field containing the
formula is semicolon).
@UserPrivileges
2. This form formula causes the Marketing Report form to be used if the current user has been assigned
the first privilege in the list (regardless of what it is called); otherwise, the Main Topic form is used.
@If(@UserPrivileges = "1"; "Marketing Report"; "Main Topic")
@UserRoles
For a database on a server or a local database with Enforce a consistent Access Control List across all
replicas in effect, returns a list of roles that the current user has. Roles are defined in a databases access
control list.
Syntax
@UserRoles
Return value
roles
Text list. Each item in the list is the name of a role that the current user has in the current database. The
role names are enclosed in brackets. Returns an empty string () if the current database is local and
Enforce a consistent Access Control List across all replicas is not in effect.
Usage
This function does not work in column, selection, mail agent, or scheduled agent formulas.
Choose File - Database - Access Control, Advanced to set Enforce a consistent Access Control List across
all replicas.
@UserRoles appends $$WebClient to the list of roles when a Web user opens a database.
Language cross-reference
Roles property of LotusScript NotesACLEntry class
Examples: @UserRoles
1. This example displays the roles assigned to the current user. The roles are displayed in brackets.
@UserRoles
2. This code, if added to the New Document action button of a database that has the Enforce a
consistent ACL across all replicas checkbox selected on the Advanced tab of the ACL Properties box,
opens the Manager form if the [Manager] role is assigned to the current user; otherwise it open the
Employee form in a Notes application.
@Command([Compose];"";@If(@IsMember("[Manager]";@UserRoles);"Manager";
"Employee"))
3. This subform formula selects a different subform depending on whether the user is a Web client or
not. The WebClient role is a role that is automatically created by Lotus Notes/Domino; it does not
require the surrounding brackets, but does require the leading double dollar signs.
@If(@IsMember("$$WebClient"; @UserRoles); "WebSubform"; "NotesSubform")
@V2If
This function performs an @If operation; the syntax is the same as for @If.
Syntax
@V2If( condition1 ; action1 ; condition2 ; action2 ; condition99 ; action99 ; else_action )
Usage
Use @V2If when you expect your application to be used with Lotus Notes Release 2.x. If the application
will only be used with Lotus Notes Release 3 or later, you should use @If. The @If function in Release 3
was redesigned to work in conjunction with the new @functions first available in Release 3, such as
@Prompt. Due to these changes, releases of Lotus Notes earlier than Release 3 cannot evaluate @If
correctly, and return an error message.
Note: In applications created with Lotus Notes prior to Release 4, the @If function is automatically
renamed to @V2If during the upgrade to Release 4.
Language cross-reference
If...Then...Else statement of LotusScript language
@V3UserName
Returns the current user name or server name. Using @V3UserName on a local database or in a private
view in a server-based database returns the users name.
If the user name is hierarchical, @V3UserName returns the name in abbreviated format (omitting the CN,
OU, O, and C identifiers). To return the name in canonical format, use @UserName.
Syntax
@V3UserName
Return value
name
Usage
When a formula runs on a server, the server is considered the current user, so @V3UserName returns the
name of the server. We do not recommend using @V3UserName in a public view. Doing so produces
unpredictable results.
One use for @V3UserName is to display only those documents relevant to the current user. For example,
your Service Request database could use @V3UserName in the private view named Assignments to
display each technicians assignments, weeding out everyone elses:
SELECT @V3UserName=AssignedTo
However, the user can still design a different private view that retrieves all documents, so dont depend
on @V3UserName as a security mechanism.
Language cross-reference
UserName property of LotusScript NotesSession class
Examples: @V3UserName
1. @V3UserName returns Robert T. Smith if this is the name associated with the current user ID and
returns Robert T. Smith/LA/Deli if this is the hierarchical name associated with the user ID.
2. @Right(@V3UserName; ) returns Fletcher if William Fletcher is the name associated with the current
user ID.
If the user ID is hierarchical, the following code returns Fletcher:
@Right(@Name([CN]; @V3UserName); " ")
3. @UpperCase(@Right(@V3UserName; )) returns FLETCHER if William Fletcher is the name
associated with the current user ID.
If the user ID is hierarchical, the following code returns FLETCHER:
@UpperCase(@Right(@Name([CN]; @V3UserName); " "))
4. Given this hierarchical user ID:
CN=Mary Tsen/OU=Illustration/OU=Documentation/OU=Development/
OU=R&D/O=WorkSavers/C=US
@V3UserName returns the name in abbreviated format:
Mary Tsen/Illustration/Documentation/Development/R&D/WorkSavers/US
To return the name in canonical format (using the CN, OU, O, and C identifiers), use @UserName.
Note: This @function is new with Release 5. If you used @UserAccess in Release 4, it is automatically
converted to @V4UserAccess in Release 5 or later to preserve the functionality of your formulas. With
Release 5 and later, more user access information is returned by @UserAccess. If you change those
formulas to use @UserAccess, be sure to recompile them under the later release. If you use @UserAccess
in Release 5 or later, a database created in Release 4 does not recognize the formula until you upgrade it.
If the formula will be evaluated in Release 4, use @V4UserAccess.
Syntax
@V4UserAccess( server : file )
Parameters
server
Text. The name of the server. Use an empty string () to indicate the local computer.
file
Text. The path and file name of the database. Specify the databases path and file name using the
appropriate format for the operating system.
Return value
level ; create ; delete
Text list.
v level is a number from 1 to 6 that indicates the users access level to the database.
v create is a number that returns 1 (True) if the user can create documents in the database, and 0 (False) if
not.
v delete is a number that returns 1 (True) if the user can delete documents from the database, and 0
(False) if not.
On a local database without Enforce a consistent Access Control List, @V4UserAccess always returns 6;
1; 1. If the current user has No Access to the database, Lotus Notes/Domino displays a message: You are
not authorized to perform that operation.
Usage
This function does not work in column or selection formulas, or in agents that run on a server (mail and
scheduled agents).
Examples: @V4UserAccess
1. This formula returns 4; 1; 1 if the user has Editor access, permission to create documents, and
permission to delete documents, in a database with the path of DSource\lookup.nsf on server
Galactica/Space/Federation.
@V4UserAccess( "Galactica//Space//Federation" : "dsource\\lookup.nsf" )
2. This formula returns 6;1;1, despite the users access level and permissions, since the customer.nsf
database is running on the local server. Or if the user has No Access to the database, You are not
authorized to perform that operation displays instead.
@V4UserAccess("":"\\Lotus\\Notes\\Data\\customer.nsf")
3. This formula returns 6; 1; 0 if the user has Manager access, permission to create documents, and no
permission to delete documents in the current database if the database is running on a server other
than the local server.
@V4UserAccess( @DbName )
@ValidateInternetAddress
Validates an Internet address based on the RFC 822 or RFC 821 Address Format Syntax.
Syntax
@ValidateInternetAddress( [ addressFormat ] ; Address )
Parameters
[ addressFormat ]
Keyword. Specifies the formatting with which to validate an Internet address. Can be one of the
following keywords:
[ADDRESS821]
SStreitfeld@gazette.com
[ADDRESS822]
Address
Usage
@ValidateInternetAddress is currently used in location records to validate Internet address fields as well
as in mail forms. This function is most useful in field validation formulas where users are asked to input
their Internet address or in computed fields where Internet addresses are inherited.
Note: Multi-byte, or 8-bit characters, are allowed in the Phrase part of an RFC 822 format Internet
address. They are not allowed anywhere else. Also, the Group syntax (i.e. several Internet addresses
combined into one group name, such as Customers) is not supported in the validator.
Examples: @ValidateInternetAddress
You have designed a form asking the user to input an Internet address. The user enters a standard RFC
821 format Internet address SStreitfeld@gazette.com in the editable field User_Address.
the validation formula returns the NULL string indicating a successful validation.
@VerifyPassword
Compares two passwords.
Syntax
@VerifyPassword( password ; password )
Parameters
password
Return value
flag
Boolean.
v Returns 1 (True) if the passwords are equivalent.
v Returns 0 (False) if the passwords are not equivalent.
Usage
Use this function to verify which password format, @Password or @HashPassword, was used to encode a
password field.
@Language cross-reference
VerifyPassword method of LotusScript NotesSession class
Examples: @VerifyPassword
1. This example returns true:
@VerifyPassword("tolstoy";@HashPassword("tolstoy"))
2. This example returns false because the hashed string contains an upper-case T:
@VerifyPassword("tolstoy";@HashPassword("Tolstoy")
3. If the access field is a password field containing the string, He++llo, this code returns true:
@VerifyPassword(access;@Password(access))
4. This code returns false because the @HashPassword and @Password functions use different formats to
encode the contents of the access field:
@VerifyPassword(@HashPassword(access);@Password(access))
@Version
Returns the release number of the Notes/Domino software youre running.
Return value
versionNumber
Usage
In column, selection, mail agent, and scheduled agent formulas, @Version returns the release number of
the Notes/Domino server or workstation containing the database. In all other formulas, @Version returns
the release number of the Notes/Domino workstation running the formula.
The following table maps the numbers returned by @Version to each Notes/Domino version.
Language cross-reference
NotesBuildVersion property of LotusScript NotesSession class
@ViewShowThisUnread
Changes a view to show only unread documents, or to show read and unread documents.
Syntax
@ViewShowThisUnread( unreadOnly )
Text.
v The value 1 shows only unread documents.
v The value 0 (or any value but 1) shows read and unread documents.
Return value
flag
Usage
This @function is intended for use in view actions.
@ViewTitle
Returns the current views name. If there are aliases and synonyms, they are returned in a text list.
Syntax
@ViewTitle
Return value
title
Usage
This function works in toolbar button, hotspot, or form action formulas, if the formula opens to a view
using an @command such as FileOpenDatabase. It can be used in hide-when formulas for view action
bars, but not for other hide-when formulas. Returns the name of the view that was last accessed when
used in field, form action, section editor, or window title formulas or null if no view has been accessed. It
does not work in column, selection, mail agent, paste agent, or scheduled agent formulas.
Language cross-reference
Name property of LotusScript NotesView class
Examples: @ViewTitle
1. This example returns Main View if that is the title of the current view.
@ViewTitle
2. This example returns Main View:By Date if the view name is Main View|By Date.
@ViewTitle
3. This example returns MAIN VIEW if the title of the current view is main view in any combination
of uppercase and lowercase letters.
@WebDbName
Returns the name of the current database encoded for URL inclusion.
Syntax
@WebDbName
Return value
databaseName
Usage
The return value can be placed as is in a URL command.
URL encoding changes most special characters to the text %xx where xx is a hexadecimal number
representing the value of the character. In particular, spaces are changed to %20.
A backslash (\) is changed to a forward slash (/) rather than encoded. Double backslashes (\\) are
removed. Dashes (-) are passed through as is.
This function is most effective when used in Web applications. When executed from the Notes client,
with @URLOpen, for example, specify the host name before this function or the URL command will not
execute properly:
@URLOpen("//hostname/" + @WebDbName + "/viewname?OpenView")
Language cross-reference
GetURLHeaderInfo method of LotusScript NotesDatabase class
Examples: @WebDbName
In an application accessed from the Web, this action opens View A in the current database. Note that
View+A could also be written as View%20A in the formula.
@URLOpen(@WebDbName + "/View+A?OpenView")
@Weekday
Computes the day of the week and returns a number that identifies the day.
Syntax
@Weekday( timedate )
Return value
weekdayNumber
Number. Weekday numbers are 1 through 7, with Sunday = 1, Monday = 2, and so on.
Language cross-reference
Weekday function of LotusScript language
Examples: @Weekday
1. This example returns 5.
@Weekday([9/29/88])
2. This example returns 2 if the date in the response field happens to fall on a Monday.
@Weekday(ResponseDate)
3. This example returns the string Working on the Weekend if the contents of the field named
ResponseDate is 7 (Saturday) or 1 (Sunday); otherwise, it returns the date the document was created
as a text string.
@If(@Weekday(ResponseDate) = 7 | @Weekday(ResponseDate) = 1;"Working on the Weekend";@Text(@Created))
@While
Executes one or more statements iteratively while a condition remains true. Checks the condition before
executing the statements.
Syntax
@While( condition ; statement ; ... )
Parameters
condition
statement
A formula language statement. The maximum number of statements you can include is 254.
Return value
true
True (1) unless an error occurs during execution of the condition. An unexpected data type error occurs
if the conditional expression results in a non-numeric value.
Usage
@While evaluates the condition. If the condition is True (1), @While executes the statements then
evaluates the condition again. If the condition is False (0), @While terminates.
Language cross-reference
While statement of LotusScript language
Examples: @While
This agent displays the elements of the Categories field one at a time.
n := 1;
@While(n <= @Elements(Categories);
@Prompt([OK]; "Category " + @Text(n); Categories[n]);
n := n + 1)
@Wide
Converts half-pitch alphanumeric characters (single-byte characters -- SBCS) in the specified string to
full-pitch alphanumeric characters (double-byte characters -- DBCS). This function works in Japanese,
Korean, Simplified Chinese, and traditional Chinese environments. In the Japanese environment, this
function can convert half-pitch Katakana as well.
Syntax
@Wide( string )
Parameters
string
Return value
returnstring
Usage
This function can be used in input translation formulas to convert a fields contents to double-byte
characters or in computed field formulas to save space for displaying a string.
Language cross-reference
StrConv function of LotusScript language
Examples: @Wide
1. This input translation formula returns Tokyo as a full-pitch character, if the Location field contains a
half-pitch character expression of Tokyo.
@Wide(Location)
2. This computed field formula returns New York as a full-pitch character, to save space for displaying
the string.
@Word
Returns the specified word from a text string. A word is defined as the part of a string that is delimited
by the defined separator character. For example, if you specify a space ( ) as the separator, then a word
is any series of characters preceded by and followed by a space (or the beginning or end of the string).
Syntax
string
separator
Text. The character that you want used to delimit a word in the string.
number
Number. A position indicating which word you want returned from string. A positive number refers to
the position of the word starting from the beginning where 1 is the first word. A negative number refers
to the position of the word starting from the end where -1 is the last word.
Return value
word
Text or text list. The word that holds the position specified by the number in the string; for example, if
number is 3, @Word returns the third word in the string. If a text list is used, @Word returns (in list
format) a word from each list that holds the specified position. Returns an empty string if number is out
of range, except that 0 is equivalent to 1.
Language cross-reference
StrToken function of LotusScript language
Examples: @Word
1. This example returns Collins,.
@Word("Larson, Collins, and Jensen"; " " ; 2)
2. This example returns Collins,:Marketing,.
@Word("Larson, Collins, and Jensen":"Sales, Marketing, and Administration";" ";2)
3. This example returns M.; here, the specified separator is the comma. The string contains 3 words:
Larson, James, and M.
@Word("Larson,James,M.";",";3)
4. This example returns Larson if James Larson is the name associated with the current user ID. It
returns M. if James M. Larson is the name associated with the current user ID.
@Word(@Username;" ";2)
5. This example returns Larson if James Larson is the name associated with the current user ID. It also
returns Larson if James M. Larson is the name associated with the current user ID.
@Word(@Username;" ";-1)
Syntax
@Year( timedate )
Parameters
time-date
Return value
year
Number. The year of time-date. @Year returns the year relative to the time zone in which the date was
generated. Returns -1 if the time-date provided contains only a time value and not a date.
Language cross-reference
Year function of LotusScript language
Examples: @Year
This example returns 1995.
@Year([9/29/95])
@Yes
Returns the value 1.
Syntax
@Yes
Return value
yes
Usage
This function is equivalent to @True.
Language cross-reference
Built-in constants of LotusScript language
Examples: @Yes
1. This example returns 1.
@Yes
2. This example returns 1 if the value in the Cost field is greater than 100.
@If(Cost>100;@Yes;@No)
Syntax
@Yesterday
Return value
yesterday
Usage
Using @Yesterday in column or selection formulas may impact the efficiency of your application. It also
causes the view refresh indicator to display constantly.
In a field formula, Lotus Notes/Domino takes the value for @Yesterday from the clock in the client
computer.
Language cross-reference
Yesterday property of LotusScript NotesInternational class
Examples: @Yesterday
1. This example returns 12/31/92 if today is January 1, 1993.
@Yesterday
2. This example returns 8/16/93 if today is August 17, 1993.
@Yesterday
@Zone
Returns the time zone setting of the current computer or of a time-date value, and indicates if
daylight-saving time is observed.
The time zone is represented as the number of hours that must be added to the time-date to convert it to
Greenwich Mean Time.
Syntax
@Zone @Zone( timeDate )
Parameters
timeDate
Time-date. Optional. The time-date whose zone you want to know. You must specify both a date and a
time; otherwise, @Zone returns 0.
Return value
zoneNumber . dstFlag
Number. The time zone, followed by a period, followed by a flag indicating daylight-saving time.
Usage
When used without a parameter, @Zone returns the zone and daylight-saving time setting of the current
computer.
When used with the parameter currentTimeDate, @Zone returns the zone and daylight-saving time setting
of currentTimeDate.
mmhh . dstFlag
dstFlag is .1 if daylight-saving time is being observed. Otherwise, only the mmhh is returned.
For example, on a computer with a time zone setting eleven and a half hours west of GMT, with
daylight-saving time disabled, @Zone returns: 3011
On a computer with a time zone setting ten and three-quarter hours west of GMT, with daylight-saving
time enabled, @Zone returns: 4510.1
On a computer with a time zone setting nine and a half hours east of GMT, with daylight-saving time
enabled, @Zone returns: -3009.1
Language cross-reference
TimeZone property of LotusScript NotesDateTime class
Examples: @Zone
1. This example returns:
v 5.1 for Eastern Standard Time and daylight saving time observed.
v 5 for Eastern Standard Time and daylight saving time not observed.
v 6 for Central Standard Time and daylight saving time not observed.
v 7.1 for Mountain Standard Time and daylight saving time observed.
v 8.1 for Pacific Standard Time and daylight saving time observed.
@Zone
2. This example returns 5 if in the Eastern Standard time zone.
@Zone([1/26/94 11:00 AM])
3. This example returns 5.1 if in the Eastern Standard time zone and daylight saving time is observed, 5
if daylight saving time is not observed.
@Zone([5/28/94 11:00 AM])
Using @Commands
An @command executes a Domino command. All of the standard menu commands can be executed
using @commands. In addition, a number of specialized commands are available.
Syntax
@Command( [ commandName ] ; parameters )
Parameters
[ commandName ]
parameters
Zero, one, or more parameters, depending on the @command youre calling. Separate parameters with
semicolons.
Return value
Number.
v 1 if the @command executes successfully
v 0 if the @command does not execute successfully
475
v Ability to export data (exp)
AddBookmark @Command
Adds a bookmark with the specified URL or current object.
Syntax
@Command( [AddBookmark] ; urlstring )
Parameters
urlstring
Text. Optional. The URL string for the database that you would like to bookmark. If you specify a null
() string, this function takes the current object using the Domino URL scheme as the object to be
bookmarked. You can specify the url string for a database by specifying its replica id, without the colon,
and preceding it with the Notes:/// prefix. The Notes URL for a database displays in the Address bar
at the top of the Notes client window if you click the down arrow button.
Text. Optional. The title that you would like to specify for the bookmark. If you specify a null () string,
you get a default title.
folder
Text. The name of the folder where you would like to place the bookmark. If you specify a null ()
string, this function will select either an open bookmark page, or a default bookmark folder.
Usage
This command does not work on the Web.
Examples: AddBookmark
1. This example, when triggered from a hotspot button on a form, creates a bookmark, named User
Log, for the 873476CD:0070A010 replica of the UserLog database in the Logs folder on the current
users bookmark bar.
@Command([AddBookmark];"Notes:///873476CD0070A010";"User Log";"Logs")
2. This example, when triggered from a hotspot button on a form, creates a bookmark, named
Feedback1, for the 641599VW:0030C007 replica of the Feedback database (which resides on the
Acme/South/Notes server) in the ProductOne Customers folder on the current users bookmark bar.
@Command([AddBookmark];"Notes/Acme/641599VW0030C007";"Feedback1";"ProductOneCustomers")
AddDatabase @Command
Adds the specified database icon to the users workspace, without opening the database.
Syntax
@Command( [AddDatabase] ; server : database ; bookmark )
Parameters
server
database
bookmark
Text (0 or 1). Optional. Specify 1 to bring up the Add Bookmark dialog box. Here, you can select or
create a folder in which the bookmark should be placed. If you specify 0 or omit this parameter, it will
bookmark the database in the Databases folder.
Usage
This command does not work on the Web.
Language cross-reference
AddDatabase method of LotusScript NotesUIWorkspace class
AddDatabaseRepID @Command
Adds an icon to the desktop for the database specified by its replica ID.
Syntax
@Command( [AddDatabaseRepID] ; replicaID ; serverHint ; bookmark )
Parameters
replicaID
serverHint
Text. Optional. The name of the server where the replica might reside. Notes checks this server for the
replica before checking the other servers.
bookmark
Text (0 or 1). Optional. Specify 1 to bring up the Add Bookmark dialog box. Here, you can select or
create a folder in which the bookmark should be placed. If you specify 0 or omit this parameter, it will
bookmark the database in the Databases folder.
Usage
AddDatabaseRepID is similar to @Command( [AddDatabase] ) but uses a replica ID instead of a
server/path name.
The database has to exist in the Notes Data directory on the server, otherwise it will not be found.
AddToIMContactList @Command
Adds a name or names to a personal group in the Instant Messaging Contact List.
Syntax
@Command( [AddToIMContactList] ; names ; personalGroup )
personalGroup
Text. Optional. The name of a personal group. If this parameter is omitted, the user is prompted with a
list of personal group names.
AdminCertify @Command
Displays the Choose Certifier ID dialog box, where you can select a Certifier ID file. After selecting a
Certifier ID and entering its password, you select the user or server ID to be certified.
Syntax
@Command( [AdminCertify] )
Usage
This command works almost anywhere in IBM Lotus Notes/Domino except from within a dialog box or
on the Web.
Language cross-reference
RegisterNewCertifier method of LotusScript NotesRegistration class
AdminCreateGroup @Command
Opens a Domino Directory and displays a blank Group form.
Syntax
@Command( [AdminCreateGroup] )
Usage
AdminCreateGroup is available only when the Domino Administrator is open.
When there is only one Domino Directory on the selected server, AdminCreateGroup opens it and
displays a blank Group form so that you can add a new group to it. When there are multiple Domino
Directories on the selected server, Notes/Domino displays a dialog box that allows you to select the
Directory to open.
AdminCrossCertifyIDFile @Command
Displays the Choose Certifier ID dialog box, where you can select a Certifier ID file. After you select a
Certifier ID and enter its password, Notes displays the Choose ID to be Cross-Certified dialog box, which
allows you to create a hierarchical cross certificate for an ID in another organization.
Usage
This command does not work on the Web.
Language cross-reference
CrossCertify method of LotusScript NotesRegistration class
AdminCrossCertifyKey @Command
Displays the Choose Certifier ID dialog box, where you can select a Certifier ID file. After you select a
Certifier ID and enter its password, Notes displays the Cross Certify Key dialog box, which allows you to
create a cross certificate for an ID in another organization using the numeric key associated with that ID.
Syntax
@Command( [AdminCrossCertifyKey] )
Usage
This command does not work on the Web.
AdminDatabaseAnalysis @Command
Displays the Database Analysis dialog box, which provides information about the selected database on
the selected server.
Syntax
@Command( [AdminDatabaseAnalysis] )
Usage
AdminDatabaseAnalysis is available only when the Domino Administrator is open.
AdminDatabaseQuotas @Command
For the selected server, displays a list of the databases in which you can change the size limits.
Syntax
@Command( [AdminDatabaseQuotas] )
Usage
AdminDatabaseQuotas is available only when the Domino Administrator is open.
AdminIDFileClearPassword @Command
Allows the administrator to delete the password associated with any user ID file, without having to first
switch to that ID and make it active.
Syntax
@Command( [AdminIDFileClearPassword] )
Usage
This command works almost anywhere in Notes/Domino except from within a dialog box or on the Web.
AdminIDFileExamine @Command
Displays the Choose ID File to Examine dialog box. After the administrator selects an ID, Notes/Domino
displays the ID Properties box, which contains information about security basics and your identity.
Syntax
@Command( [AdminIDFileExamine] )
Usage
This command works almost anywhere in Notes/Domino except from within a dialog box or on the Web.
AdminIDFileSetPassword @Command
Allows the administrator to assign a password to any user ID file, without having to first switch to that
ID and make it active.
Syntax
@Command( [AdminIDFileSetPassword] )
Usage
This command can be used almost anywhere in Notes/Domino except from within a dialog box or on
the Web. This command is particularly useful for changing the password on a Certifier ID.
Administration @Command
Opens the Domino Administrator if the Domino Administrator package is installed on the local machine
of the user executing the command.
Syntax
@Command( [Administration] )
Usage
This command works anywhere in Notes/Domino except from within a dialog box or on the Web.
Syntax
@Command( [AdminNewOrganization] )
Usage
This command works anywhere in Notes/Domino except from within a dialog box or on the Web.
Language cross-reference
RegisterNewCertifier method of LotusScript NotesRegistration class
AdminNewOrgUnit @Command
Prompts for the Certifier ID password and then displays the Register Organizational Unit Certifier dialog
box, where the administrator can create a hierarchical Certifier ID for an organizational unit.
Syntax
@Command( [AdminNewOrgUnit] )
Usage
This command works anywhere in Notes/Domino except from within a dialog box or on the Web.
Language cross-reference
OrgUnit property of LotusScript NotesRegistration class
AdminOpenAddressBook @Command
Opens a Domino Directory on the selected server.
Syntax
@Command( [AdminOpenAddressBook] )
Usage
AdminOpenAddressBook is available only when the Domino Administrator is open.
When there is only one Domino Directory on the selected server, AdminOpenAddressBook opens it.
When there are multiple Directories on the selected server, Notes/Domino displays a dialog box that
allows you to select the Directory to open.
AdminOpenCatalog @Command
Opens the database catalog (CATALOG.NSF) on the selected server.
Syntax
@Command( [AdminOpenCatalog] )
Usage
AdminOpenCatalog is available only when the Domino Administrator is open.
Language cross-reference
IsDirectoryCatalog property of LotusScript NotesDatabase class
AdminOpenCertLog @Command
Opens the certification log (CERTLOG.NSF) on the selected server.
Syntax
@Command( [AdminOpenCertLog] )
Usage
AdminOpenCertlog is available only when the Domino Administrator is open.
In order for AdminOpenCertLog to operate successfully, there must be a copy of a database named
certlog.nsf on the selected server.
AdminOpenGroupsView @Command
Opens a Domino Directory on the selected server and displays its Groups view.
Syntax
@Command( [AdminOpenGroupsView] )
Usage
AdminOpenGroupsView is available only when the Domino Administrator is open.
When there is only one Domino Directory on the selected server, AdminOpenGroupsView opens it and
displays its Groups view. When there are multiple directories on the selected server, Notes/Domino
displays a dialog box that allows you to select the directory to open.
Language cross-reference
GetView method of LotusScript NotesDatabase class
AdminOpenServerLog @Command
Opens the server log (LOG.NSF) on the selected server.
Syntax
@Command( [AdminOpenServerLog] )
Usage
AdminOpenServerLog is available only when the Domino Administrator is open.
Language cross-reference
OpenDatabase method of LotusScript NotesUIWorkspace class
AdminOpenServersView @Command
Opens a Domino Directory on the selected server and displays its Servers view.
Syntax
@Command( [AdminOpenServersView] )
Usage
When there is only one Domino Directory on the selected server, AdminOpenServersView opens it and
displays its Servers view. When there are multiple Domino directories on the selected server,
Notes/Domino displays a dialog box that allows you to select the directory to open.
Language cross-reference
GetView method of LotusScript NotesDatabase class
AdminOpenStatistics @Command
Opens the statistics reporting database (STATREP5.NSF) on the selected server.
Usage
AdminOpenStatistics is available only when the Domino Administrator is open.
For AdminOpenStatistics to operate successfully, there has to be a database named STATREP5.NSF on the
selected server. Domino creates this database the first time it starts the REPORT server event.
Language cross-reference
OpenDatabase method of LotusScript NotesUIWorkspace class
AdminOpenUsersView @Command
Opens a Domino Directory on the selected server and displays its People view.
Syntax
@Command( [AdminOpenUsersView] )
Usage
AdminOpenUsersView is available only when the Domino Administrator is open.
When there is only one Domino Directory on the selected server, AdminOpenUsersView opens it and
displays its People view. When there are multiple Domino directories on the selected server,
Notes/Domino displays a dialog box that allows you to select the directory to open.
Language cross-reference
GetView method of LotusScript NotesDatabase class
AdminOutgoingMail @Command
Displays the contents of the selected servers MAIL.BOX file.
Syntax
@Command( [AdminOutgoingMail] )
Usage
AdminOutgoingMail is available only when the Domino Administrator is open.
Syntax
@Command( [AdminRegisterFromFile] )
Usage
This command works almost anywhere in Notes/Domino except from within a dialog box or on the Web.
AdminRegisterServer @Command
Displays a series of dialog boxes for creating a new server ID.
Syntax
@Command( [AdminRegisterServer] )
Usage
This command works anywhere in Notes/Domino except from within a dialog box or on the Web.
Language cross-reference
RegisterNewServer method of LotusScript NotesRegistration class
AdminRegisterUser @Command
Displays a series of dialog boxes for certifying new users.
Syntax
@Command( [AdminRegisterUser] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box or on the Web.
Language cross-reference
RegisterNewUser method of LotusScript NotesRegistration class
AdminRemoteConsole @Command
Displays the Remote Server Console dialog box, where an administrator can enter server console
commands from a workstation.
Syntax
@Command( [AdminRemoteConsole] )
Usage
This command works anywhere in Notes/Domino except from within a dialog box or on the Web.
Syntax
@Command( [AdminSendMailTrace] )
Usage
AdminSendMailTrace is available only when the Domino Administrator is open.
You use AdminSendMailTrace to determine the source of a mail delivery failure or to see if it is possible
to deliver mail to a specific address.
AdminStatisticsConfig @Command
Opens the server events database (EVENTS4.NSF) on the selected server and displays its Servers to
Monitor view.
Syntax
@Command( [AdminStatisticsConfig] )
Usage
AdminStatisticsConfig is available only when the Domino Administrator is open.
Language cross-reference
GetView method of LotusScript NotesDatabase class
AdminTraceConnection @Command
Displays the Trace Connections dialog box, which allows you to test network connections through a
passthru server.
Syntax
@Command( [AdminTraceConnection] )
Usage
This command does not work on the Web.
Syntax
@Command( [AgentEdit] )
Usage
An agent must be selected in the Agents view of a database.
Language cross-reference
GetAgent method of LotusScript NotesDatabase class
AgentEnableDisable @Command
Enables or disables the specified agent.
Syntax
@Command( [AgentEnableDisable] ; agentName ; enableState )
Parameters
agentName
Text. Optional. The name of a scheduled agent defined for the currently selected database. If you omit
this parameter, AgentEnableDisable applies to the currently selected agent.
enableState
Number (1 or 0). Optional. A value of 1 specifies that the agent is to be enabled. A value of 0
specifies that the agent is to be disabled. If you omit this parameter, AgentEnableDisable changes the
agents current state from enabled to disabled or from disabled to enabled.
Usage
You can omit both parameters when an Agents window has focus and a scheduled agent is selected.
Otherwise, agentName is required.
Language cross-reference
IsEnabled property of LotusScript NotesAgent class
AgentLog @Command
Displays the log for the currently selected agent. The log contains information about when the agent last
ran, what actions it performed, and when it finished running.
Usage
An agent must be selected in the Agents view of a database. The agent must have run at least once.
Language cross-reference
LastRun property of LotusScript NotesAgent class
AgentRun @Command
Runs the currently selected agent and then displays its log.
Syntax
@Command( [AgentRun] )
Usage
An agent must be selected in the Agents view of a database.
Language cross-reference
Run method of LotusScript NotesAgent class
AgentSetServerName @Command
Specifies a scheduled agent to run on a particular server.
Syntax
@Command( [AgentSetServerName] ; agentName ; serverName )
Parameters
agentName
serverName
Text. Optional. The name of the server on which you want agentName to run. If you omit this parameter,
Notes/Domino displays the Choose Server To Run On dialog box when AgentSetServerName executes.
Usage
This command does not work on the Web.
AgentTestRun @Command
Displays a log for the currently selected agent, describing what actions the agent will perform when run.
Syntax
@Command( [AgentTestRun] )
Usage
An agent must be selected in the Agents view of a database.
Language cross-reference
Comment property of LotusScript NotesAgent class
AttachmentDetachAll @Command
Displays the Save Attachments To dialog box, where you select a location for the current documents
attachments.
Syntax
@Command( [AttachmentDetachAll] )
Usage
v A document must be open in Read or Edit mode.
v A form or subform must be open in Design mode.
The document must have two or more attachments and at least one must be selected.
This @command does not work when used in a hotspot button. The hotspot button takes focus away
from the attachment that must be selected to be detached. Use an action button instead.
This @command does not work on the Web. To detach an attachment from a form via a Web browser, a
user can click the attachments icon.
Language cross-reference
ExtractFile method of LotusScript NotesEmbeddedObject class
AttachmentLaunch @Command
Launches the selected attachment by opening the application in which it was created, if possible.
Usage
v A document must be open in Read or Edit mode.
v A form or subform must be open in Design mode.
v An attachment must be selected.
This @command does not work in Web applications. If a rich-text field on a form contains an attachment
on the Web and you click the attachments icon, Notes either launches the attachment (TXT files, for
example) or prompts the user to detach the file by saving it to disk (NSF files, for example).
This @command does not work when used in a hotspot button. The hotspot button takes focus away
from the attachment that must be selected to be launched. Use in an action button instead.
If the users machine does not have the program that runs the attachment being launched, the following
error is generated, Sorry, an application to open this document cannot be found.
Language cross-reference
Shell function of LotusScript language
Examples: @Command([AttachmentLaunch])
This formula, when added to a Launch action button on a form, launches the Notepad file,
LICENSE.TXT, which is attached to a rich-text field on the form. First, you click the LICENSE.TXT icon to
select it, then you click the Launch button. The program NOTEPAD.EXE launches, displaying the
LICENSE.TXT file.
@Command([AttachmentLaunch])
AttachmentProperties @Command
Displays the Properties box for the current attachment.
Syntax
@Command( [AttachmentProperties] )
Usage
v A document must be open in Read or Edit mode.
v A form or subform must be open in Design mode.
v An attachment must be selected.
This @command does not work when used in a hotspot button. The hotspot button takes focus away
from the attachment that must be selected for the Properties box to display. Use in an action button
instead.
AttachmentView @Command
Launches the Attachment Viewer, which lets you view the contents of the selected attachment without
opening the application in which it was created.
Usage
v A document must be open in Read or Edit mode.
v A form or subform must be open in Design mode.
v An attachment must be selected.
This @command does not work when used in a hotspot button. The hotspot button takes focus away
from the attachment that must be selected to be viewed. Use in an action button instead.
CalendarFormat @Command
Changes the Calendar view to display one day, two days, one week, two weeks, one month, or one year.
Syntax
@Command( [CalendarFormat] ; format )
Parameters
format
Usage
With no parameters, CalendarFormat cycles to the next calendar display option, in this order: One Day,
Two Days, One Week, Two Weeks, One Month. With parameters, CalendarFormat changes to the
designated display.
CalendarGoTo @Command
Goes to a particular date in a Calendar view.
Syntax
@Command( [CalendarGoTo] ; timedate )
Parameters
time-date
Usage
With no parameters, CalendarGoTo displays the View Calendar GoTo dialog box. With parameters,
CalendarGoTo moves the view focus to the requested date.
CheckCalendar @Command
Pops up a dialog box containing a one-day calendar view. The current database must contain a calendar
view for this command to function properly.
Syntax
@Command( [CheckCalendar]; timedate )
Parameters
timedate
Time-date. Optional. Specify the date you want to view in the one-day calendar that displays in the
dialog box. If no date is supplied, todays date displays by default.
Usage
You can add this command to action button code in a mail memo to enable recipients of meeting
invitations to check their calendars without having to toggle between their Calendar and Inbox views; the
recipient can click and drag the dialog box.
Examples: CheckCalendar
1. The following code, when added to an action button on a Notice form, which is a form that notifies
meeting invitees of the time and location of a meeting, displays a dialog box containing a one-day
view of the invitees calendar. Notes determines the day to display in the view based on the dates
specified in the StartDate, DueDate, or NewStartDate fields, in that order. It displays the calendar
information for the first date it encounters; if none of the fields contains a date, it displays todays
date:
DateToDisplay := @If(@IsAvailable(StartDate);StartDate;
@IsAvailable(DueDate);DueDate;@IsAvailable(NewStartDate);NewStartDate;
@Today);
@Command([CheckCalendar]; DateToDisplay)
ChooseFolders @Command
Displays the Folders dialog box, which allows you to select a folder in which to file the current
document.
Syntax
@Command( [ChooseFolders] )
Language cross-reference
Folder method of LotusScript NotesUIWorkspace class
Clear @Command
Performs the menu command Edit Delete.
Syntax
@Command( [Clear] )
Usage
This command executes immediately. Use the EditClear @command to execute after all @functions. See
the Order of evaluation for formula statements topic for more details.
In a view, folder, or a document in Read mode in a Notes application, marks the currently selected
document for deletion. If you include functions that access or assign values to fields or properties in that
document after this @command in a formula, they are ignored.
In a document in Edit mode, deletes the highlighted data (text, tables, graphics, links, file attachments, or
objects).
In Web applications, only use this command on a form to delete the entire current document. It cannot be
used to delete highlighted data on a form in Edit mode; if executed on a form, it deletes the entire
document. You cannot use this command to mark selected documents in a view for deletion. Use the
MoveToTrash @Command instead. To customize the Deleted confirmation page returned by the server,
create a form named $$ReturnDocumentDeleted. See Customizing Form processed confirmation for
the Web in the Application Development with Domino Designer guide for details.
In Notes applications, when this command is called on a form, subform, view, or folder in Design mode,
it deletes the highlighted data, fields, or columns.
On the workspace, removes the selected icon (without permanently deleting the database from disk).
Language cross-reference
Clear method in LotusScript NotesUIDocument class
CloseWindow @Command
Closes the current Notes window. If the document or design element in that window has not been saved,
Notes prompts the user to save it before closing.
Syntax
@Command( [CloseWindow] )
Usage
This command executes immediately. Use the FileCloseWindow @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
When using this command on a form in Notes, you can prevent the user from being prompted to save
any changes.
You can use this command with Web applications, as long as you enable the Allow Javascript on the
Web setting on the Basics tab of the Database Properties box. Precede this command with
@Command([FileSave]) to simulate a Submit button.
Language cross-reference
Close method of LotusScript NotesUIView class
Examples: @Command([CloseWindow])
1. This code, when added to an action button on a form and accessed from a Web application, saves and
closes the current document and opens the Results view. Following CloseWindow with the OpenView
@command prevents the default Form Processed page from displaying and instead brings the user to
the specified view.
@Command([FileSave]);
@Command([CloseWindow]);
@Command([OpenView];"Results")
Compose @Command
Creates a new, blank document.
Syntax
@Command([Compose]; server : database ; form ; width : height )
Parameters
server : database
form
Text. The name of the form you want to use when creating the new document.
width : height
Number list. Optional. The width and height, in inches, of the window for the document you compose. If
you omit this parameter, or use zero for either value, you create the window at the default size (usually
the size that the last user set).
Usage
To use this command in Web applications, use the following syntax:
@Command([Compose]; form)
When you compose a response document, make sure a database is open and a document is already
selected at the view level. See ComposeWithReference for composing response documents with references
to the main document.
When the command is used to compose main documents, the target database does not have to be open.
This command adds a database icon to the workspace.
If the command is used in a view action, the form formula of the view will override the form specified in
the @command. To avoid this problem add the following line to the form formula of the view:
@If(@IsNewDoc; @Return(Form); "")
For information about form formulas, see Form Formulas in Programming Overview.
The width/height parameter does not apply in MDI mode when the window is maximized. When
restored, the window returns to the size you specify. The measurement in inches matches the ruler bar in
the editor, so that you can use the ruler bar to guide you in sizing the window. When you specify the
width and height, you center the window in the enclosing Notes window (for MDI mode) or in the
operating desktop (for Mac and SDI mode).
Language cross-reference
CreateDocument method in LotusScript NotesDatabase class
Examples: Compose
1. The following formula composes a new MainTopic document in the current database.
@Command([Compose]; ""; "MainTopic")
2. The following formula composes a new Client Information document in the REPS.NSF database in the
Westchester directory of the sales/nyoffice server.
@Command([Compose]; "SALES//nyoffice" : "Westchester\\REPS.NSF"; "Client Information")
3. The following formula composes a mail memo in the users own Mail database.
@Command([Compose]; @MailDbName; "Memo")
ComposeWithReference @Command
Creates a response document containing a reference to the main document.
Syntax
@Command([ComposeWithReference]; server : database ; form ; flags )
Parameters
server : database
Text list. The name of the server and database where you want to create the document. Null for server
means the local Domino or Notes directory; must be null on the Web. Null for server and database means
the current database.
form
Text. The name of the form you want to use when creating the new document. This form must contain a
rich text or rich text lite field named Body.
flags
Number. Optional. One or more of the following reference attributes. Combine attributes by adding them.
Defaults to flags 3 plus 4. You must supply this parameter in Web applications.
v 0 -- includes Body in a collapsible section (flags 3 plus 4, the default). Cannot be combined with other
flags. Does not work on Web.
v 1 -- Includes a reference to the main document. Cannot be combined with other flags. Does not work
on Web.
v 2 -- Includes no history. Cannot be combined with other flags.
v 3 -- Includes the Body of the main document. Can be combined with the flags that follow.
v 4 -- Puts the Body of the main document in a collapsible section. Does not work on Web.
v 8 -- Includes Body as an Internet-style copy of the main document, with a So-and-so wrote on ...
header and each line prefixed by a greater-than sign. Requires flag value 2. Implicitly applies flag 16.
Does not work on Web.
v 16 -- Removes attachments, images, and other large objects from the reference copy, replacing them
(except on the Web) with text statements in brackets.
v 32 -- For databases that contain a $ForwardSep subform (as exists in the Release 6 mail template),
prefixes the reference copy with a forward separator. Does not work on Web.
Usage
When composing a response document, make sure a database is open and a document is already selected
at the view level.
For information about form formulas, see Form Formulas in Programming Overview.
Language cross-reference
MakeReponse method of LotusScript NotesDocument class
Examples: ComposeWithReference
1. This example, which could be a form or view action, creates a response document based on the
Reply form containing a link to the main document.
@Command([ComposeWithReference]; ""; "Reply"; 1)
2. This example creates a response document with no copy of or reference to the main document.
@Command([ComposeWithReference]; ""; "Reply"; 2)
3. This example creates a response document containing a copy of the main document.
@Command([ComposeWithReference]; ""; "Reply"; 3)
4. These three examples are equivalent. Each creates a response document containing a copy of the
main document in a collapsible section.
@Command([ComposeWithReference]; ""; "Reply"; 3 + 4)
@Command([ComposeWithReference]; ""; "Reply"; 0)
@Command([ComposeWithReference]; ""; "Reply")
5. This example creates a response document containing a copy of the main document in Internet style.
@Command([ComposeWithReference]; ""; "Reply"; 3 + 8)
6. This example creates a response document containing a copy of the main document in a collapsible
section in Internet style.
@Command([ComposeWithReference]; ""; "Reply"; 3 + 4 + 8)
7. This example creates a response document containing a copy of the main document with
attachments stripped.
@Command([ComposeWithReference]; ""; "Reply"; 3 + 16)
8. This example creates a response document containing a copy of the main document in a collapsible
section with attachments stripped.
@Command([ComposeWithReference]; ""; "Reply"; 3 + 4 + 16)
9. This example, when used in an action button in a database containing a $ForwardSep subform,
composes a forwarded mail memo referencing the main document.
@Command([ComposeWithReference]; ""; "Memo"; 3 + 32)
10. This example composes a forwarded mail memo in the current database. All attachments are
stripped before the main document is copied to the new memo.
@Command([ComposeWithReference]; ""; "Memo"; 3 + 16 + 32)
11. This example composes a forwarded mail memo in the current database. The new document
contains an Internet-style quoted copy of the reference document. All attachments, images and other
large objects are stripped before the main document is copied to the new one.
@Command([ComposeWithReference]; ""; "Memo"; 3 + 8 + 32)
12. This example, when triggered from an action button on a form, checks if the current document has
been saved. If not, it saves it, then opens the responseDoc response document, including the body
of the main document in a collapsible section.
@If(@IsNewDoc;@Do(@Command([FileSave]); "");
@Command([ComposeWithReference];"";"responseDoc")
Syntax
@Command([CreateAction])
Usage
v A form or subform must be open in Design mode
or
v A view or folder must be open in Design mode
CreateAgent @Command
Creates a new agent in the current database and opens the Agent Properties box, where you can name
and define the agent.
Syntax
@Command( [CreateAgent] )
Usage
A database must be open or selected on the workspace. The user must have at least Designer access to
the database or have permission in the ACL to create private agents.
CreateControlledAccessSection @Command
Creates a controlled access section on a form or subform. Unlike a regular section, a controlled access
section has a formula to determine who can edit it.
Syntax
@Command( [CreateControlledAccessSection] )
Usage
A form or subform must be open in Design mode and the text you want in the section must be selected.
CreateEllipse @Command
Lets you create an ellipse in a navigator. After you invoke the command, the cursor changes to a
crosshair when you start to drag the mouse in the design area. You create an ellipse by dragging the
mouse until the ellipse is the size you want.
Syntax
@Command( [CreateEllipse] )
CreateFolder @Command
Displays the Create Folder dialog box, which lets you choose a location for a new folder and create it.
Syntax
@Command( [CreateFolder] )
Usage
A database must be open or selected on the workspace, and the user must have at least Designer access
to the database, or have permission in the ACL to create personal folders.
Language cross-reference
EnableFolder method of LotusScript NotesDatabase class
CreateForm @Command
Creates a new, blank form in a database.
Syntax
@Command( [CreateForm] )
Usage
A database must be open or selected on the workspace, and the user must have at least Designer access
to the database.
CreateLayoutRegion @Command
Creates a new layout region on a form or subform.
Syntax
@Command( [CreateLayoutRegion] )
Usage
A form or subform must be open in Design mode.
Syntax
@Command( [CreateNavigator] )
Usage
A database must be open or selected on the workspace, and the user must have at least designer access
to the database.
Language cross-reference
CreateViewNav method of LotusScript NotesView class
CreatePolygon @Command
Lets you create a polygon in a navigator. After you invoke the command, the cursor changes to a
crosshair when you start to drag the mouse in the design area. You create a polygon by clicking the
mouse each time you want to start a new side. Double-click when you are done.
Syntax
@Command( [CreatePolygon] )
Usage
A navigator must be open in Design mode.
CreatePolyline @Command
Lets you create a polyline in a navigator. After you invoke the command, the cursor changes to a
crosshair when you start to drag the mouse in the design area. You create a polyline by clicking the
mouse each time you want to start a new line. Double-click when you are done.
Syntax
@Command( [CreatePolyline] )
Usage
A navigator must be open in Design mode.
CreateRectangle @Command
Lets you create a rectangle in a navigator. After you invoke the command, the cursor changes to a
crosshair when you start to drag the mouse in the design area. You create a rectangle by dragging the
mouse until the rectangle is the size you want.
Usage
A navigator must be open in Design mode.
CreateRectangularHotspot @Command
Lets you create a rectangular hotspot in a navigator. After you invoke the command, the cursor changes
to a crosshair when you start to drag the mouse in the design area. You create a rectangular hotspot by
dragging the mouse until the rectangle is the size you want.
Syntax
@Command( [CreateRectangularHotspot] )
Usage
A navigator must be open in Design mode.
CreateSection @Command
Creates a section.
Syntax
@Command( [CreateSection] )
Usage
v A document must be open in Edit mode
or
v A form or subform must be open in Design mode
The text you want in the section must be selected. If you do not select any text, a blank section will be
created.
CreateSubform @Command
Creates a new, blank subform in a database.
Syntax
@Command( [CreateSubform] )
Usage
A database must be open or selected on the workspace, and the user must have at least Designer access
to the database.
Syntax
@Command( [CreateTextbox] )
Usage
A navigator must be open in Design mode.
CreateView @Command
Displays the Create View dialog box, which lets you choose a location for a new view and create it.
Syntax
@Command( [CreateView] )
Usage
A database must be open or selected on the workspace, and the user must have at least Designer access
to the database.
Language cross-reference
CreateView method of LotusScript NotesDatabase class
DatabaseDelete @Command
Permanently deletes the current database file from the hard disk where it is stored.
Syntax
@Command( [DatabaseDelete] )
Usage
This command executes immediately. Use the FileDatabaseDelete @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
A database icon must be selected, but the database cannot be open. The user must have Manager access
in order to delete the database.
Note: To remove the database icon from the users workspace without deleting the database, use
@Command([FileDatabaseRemove]).
DatabaseReplSettings @Command
Displays the Replication Settings dialog box for the current database.
Syntax
@Command( [DatabaseReplSettings] )
Usage
A database must be open or selected on the workspace.
DebugLotusScript @Command
Puts Designer into debug mode, so that all LotusScript scripts run in the debugger. The command is a
toggle; selecting it again takes Notes out of debug mode.
Syntax
@Command( [DebugLotusScript] )
Usage
This command works almost anywhere in Notes/Domino except from within a dialog box or on the Web.
Once Designer is in debug mode and the Script Debugger window is open, you cannot select this
@command again to terminate debugging. Use the Close Debugger button on the Script Debugger
window instead.
Examples: @Command([DebugLotusScript])
This formula, when added to a hotspot button labeled Debug on a document, starts the script debugger.
Once an event that has code associated with it is triggered, the Script Debugger window displays.
@Command([DebugLotusScript])
For instance, if a document with the Debug hotspot button has LotusScript code in its postmodechange
event, when you open the document from a view (in read mode), click Debug, then double-click the
document background to change it to edit mode, the Script Debugger window displays.
Tip: If you want to close the window and stop debugging, click the Close Debugger button in the Script
Debugger window. If you decide to take Designer out of debug mode before the Debugger window
displays, click the Debug hotspot button again to turn the debugger off.
DesignDocumentInfo @Command
Displays the Properties box for the current document.
Syntax
@Command( [DesignDocumentInfo] )
If multiple documents have been selected, the Properties box displays for the highlighted document.
DesignFormAttributes @Command
Displays the Properties box for the current form, subform, or page.
Syntax
@Command( [DesignFormAttributes] )
Usage
A form, subform, or page must be open in Design mode. Its most convenient to use a toolbar button to
invoke this command.
DesignFormFieldDef @Command
Displays the Properties box for the currently selected field.
Syntax
@Command( [DesignFormFieldDef] )
Usage
A form or subform must be open in Design mode, and a field must be selected. Its most convenient to
use a toolbar button to invoke this command.
DesignFormNewField @Command
Creates a new field on a form or subform.
Syntax
@Command( [DesignFormNewField] )
Usage
A form or subform must be open in Design mode and there must be no fields selected. Its most
convenient to use a toolbar button to invoke this command.
DesignForms @Command
Displays the Design - Forms view of the current database.
Usage
The user must have at least Designer access to the database.
DesignFormShareField @Command
Turns a singleuse field into a shared field.
Syntax
@Command( [DesignFormShareField] )
Usage
A form or subform must be open in Design mode and a field must be selected. Its most convenient to
use a toolbar button to invoke this command.
DesignFormUseField @Command
Displays the Insert Shared Field dialog box, where the user can select a shared field to place on the
current form or subform.
Syntax
@Command( [DesignFormUseField] )
Usage
A form or subform must be open in Design mode and there must be no fields selected. Its most
convenient to use a toolbar button to invoke this command.
DesignFormWindowTitle @Command
Displays the design pane and sets the Event edit control to Window Title, so you can define a formula for
a forms window title.
Syntax
@Command( [DesignFormWindowTitle] )
Usage
A form must be open in Design mode. Its most convenient to use a toolbar button to invoke this
command.
DesignHelpAboutDocument @Command
Displays the About document in Edit mode for the current database.
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignHelpUsingDocument @Command
Displays the Using document in Edit mode for the current database.
Syntax
@Command( [DesignHelpUsingDocument] )
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignIcon @Command
Displays the Design Icon dialog box, where you can edit the icon for the currently selected database.
Syntax
@Command( [DesignIcon] )
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignMacros @Command
Displays the Agents and Release 3 macros in the current database.
Syntax
@Command( [DesignMacros] )
Usage
A database must be open or selected on the workspace.
DesignRefresh @Command
Displays the Refresh Database Design dialog box, where the user can choose a server that contains the
design template for the current database.
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignReplace @Command
Displays the Replace Database Design dialog box, where the user can choose a design template to replace
that of the current database.
Syntax
@Command( [DesignReplace] )
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignSharedFields @Command
Displays the Design - Shared Fields view in the current database.
Syntax
@Command( [DesignSharedFields] )
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignSynopsis @Command
Displays the Design Synopsis dialog box so the user can select the types of information to be included in
the synopsis.
Syntax
@Command( [DesignSynopsis] )
Usage
This command does not work on the Web.
DesignViewAppendColumn @Command
Creates a column in a view or folder, positioned after the last column.
Usage
A view or folder must be open in Design mode.
Language cross-reference
CreateColumn method of LotusScript NotesView class
DesignViewAttributes @Command
Displays the Properties box for the current view or folder.
Syntax
@Command( [DesignViewAttributes] )
Usage
A view or folder must be open in Design mode.
DesignViewColumnDef @Command
Displays the Properties box for the currently selected column.
Syntax
@Command( [DesignViewColumnDef] )
Usage
A view or folder must be open in Design mode, and a column must be selected.
DesignViewEditActions @Command
Displays or hides the action pane.
Syntax
@Command( [DesignViewEditActions] )
Usage
A view or folder must be open in Design mode. If the action pane is visible, DesignViewEditActions
hides it; and if the action pane is not visible, DesignViewEditActions displays it.
Syntax
@Command( [DesignViewFormFormula] )
Usage
A view or folder must be open in Design mode.
DesignViewNewColumn @Command
Creates a new column before the currently selected column in a view or folder.
Syntax
@Command( [DesignViewNewColumn] )
Usage
A view or folder must be open in Design mode. Its most convenient to use a toolbar button to invoke
this command.
Language cross-reference
CreateColumn method of LotusScript NotesView class
DesignViews @Command
Displays the Design - Views view in the current database.
Syntax
@Command( [DesignViews] )
Usage
A database must be open or selected on the workspace and the user must have at least Designer access to
the database.
DesignViewSelectFormula @Command
Displays the design pane and sets the Define control to View Selection, which allows you to define a
selection formula to determine which documents are displayed in a view.
Syntax
@Command( [DesignViewSelectFormula] )
Language cross-reference
SelectionFormula property of LotusScript NotesView
DialingRules @Command
Displays the Dialing Rules dialog box, which allows you to define dialing rules for a modem in a
Location document in a Domino Directory.
Syntax
@Command( [DialingRules] )
Usage
The Location document must be open and should have focus for this @command to work.
Directories @Command
Displays the Directories dialog box which allows you to search for an address, view detailed information
about an address entry, and add an entry to your Domino Directory with the Directories dialog box.
Syntax
@Command( [Directories] )
Usage
This command does not work on the Web.
DiscoverFolders @Command
Displays the Folders containing current document dialog box.
Syntax
@Command( [DiscoverFolders] )
Usage
This command does not work on the Web.
This command works only in a design element containing an embedded outline with the Maintain
folder unread information property selected. Elsewhere in the design a document must be selected.
Otherwise, the error Cannot execute the specified command occurs.
EditBottom @Command
Moves the insertion point to the bottom of a document or form.
Syntax
@Command( [EditBottom] )
Usage
v On a form in Design mode, EditBottom moves the insertion point to the bottom of the form as if the
user had pressed ctrl+end.
v In a document in Edit mode, EditBottom moves the insertion point to the last editable field or button
on the document.
v In a document in Read mode, EditBottom has no effect.
v You can precede this command with either:
@Command([EditDocument]; 1) to put the document into edit mode
@IsDocBeingEdited function to test if the document is in edit mode
Language cross-reference
GotoBottom method in LotusScript NotesUIDocument class
EditButton @Command
Displays the design pane and the Properties box for the selected button.
Syntax
@Command( [EditButton] )
Usage
A document must be open in Edit mode and a button must be selected.
EditClear @Command
Performs the menu command Edit Delete.
Syntax
@Command( [EditClear] )
Usage
This command executes after all @functions. Use @Command([Clear]) to execute immediately. See the
Order of evaluation for formula statements topic for more details.
v In a view, folder, or a document in Read mode in a Notes application, marks the currently selected
document for deletion.
Language cross-reference
Clear method in LotusScript NotesUIDocument class
Examples: EditClear
1. The following example, when used in the DeleteField action of a form in a Notes application, deletes
the content of whichever field has focus when the DeleteField action button is pressed in edit mode:
@Command([EditGotoField]; @ThisName);
@Command([EditSelectAll]);
@Command([EditClear])
2. The following example, when used in the Delete action of a form, deletes the current document
opened in read mode on the Web. It then displays a customized form, if you created a form with the
name $$ReturnDocumentDeleted, or displays the default Deleted confirmation page.
@Command([EditClear])
3. The following example, when used in a view action of a Notes application, deletes the documents
selected in the view.
@Command([EditClear)]
EditCopy @Command
Performs the menu command Edit Copy.
Syntax
@Command( [EditCopy] )
Usage
v In a view or folder, copies the selected documents to the Clipboard.
v In a document in Read or Edit mode, copies the highlighted data to the Clipboard.
v On a form, subform, view, or folder in Design mode, copies the highlighted data, fields, or columns to
the Clipboard.
Language cross-reference
Copy method in LotusScript NotesUIDocument class
Examples: EditCopy
This form action copies the selected text in a document that is in read or edit mode. If no text is selected,
the entire document is copied.
@Command([EditCopy])
EditCut @Command
Performs the menu command Edit Cut.
Syntax
@Command( [EditCut] )
Usage
v In a view or folder, deletes the selected documents and places them on the Clipboard.
v In a document in Edit mode, deletes the highlighted data and places it on the Clipboard.
v In a document in Read mode, EditCut has no effect.
v On a form, subform, view, or folder in Design mode, deletes the highlighted data, fields, or columns
and places them on the Clipboard.
v It is most convenient to use a toolbar button to invoke this command.
Language cross-reference
Cut method in LotusScript NotesUIDocument class
EditDeselectAll @Command
Performs the menu command Edit Deselect All.
Syntax
@Command( [EditDeselectAll] )
Usage
v In a view or folder, deselects all selected documents.
v In a document in Read or Edit mode, deselects all highlighted data.
v On a form, subform, view, or folder in Design mode, deselects all highlighted data, fields, and
columns.
v On the workspace, deselects all selected databases.
EditDetach @Command
Detaches a file attachment to a location you specify.
Syntax
@Command( [EditDetach] )
or
Parameters
sourcefile
targetfile
Text. A path and file name indicating where you want to put the file. Include the complete path
specification (appropriate to the users operating system).
Usage
With no parameters, displays the Save Attachment dialog box for the current attachment. A document
must be open in Read or Edit mode and the attachment must be selected.
This command is useful in action buttons; it cannot be added to a hotspot button. It does not work on
the Web.
With both parameters, detaches the specified sourcefile and stores it using the targetfile path and file name
without displaying the Save Attachment dialog box. A document must be open in Read or Edit mode, but
since you are specifying which attachment to detach, the attachment does not have to be selected.
Language cross-reference
ExtractFile method of LotusScript NotesEmbeddedObject class
Examples: EditDetach
1. This formula displays the Save Attachment dialog box.
@Command([EditDetach])
2. This formula detaches the 123 for Macintosh worksheet Budget96 from the open document and
stores it in the folder called Worksheets on Macintosh HD, the users Macintosh workstation.
@Command([EditDetach];"BUDGET96";"Macintosh HD:Worksheets:Budget96")
Syntax
@Command( [EditDocument] )
or
Parameters
mode
Number. Specify 1 to place the document in Edit mode or 0 to place it in Read mode.
previewpane
Usage
In a view or folder, this @command opens the highlighted document in the specified mode. If the mode is
omitted, Edit mode is assumed.
When you use this command with Web applications, it edits the current document. Use this command
only on forms for the Web. The parameters for this function do not work on the Web.
On the Web, this command does not work in view actions. To open a document in Edit mode from a
view, use @Command([OpenDocument]; 1) preceded by the OpenView @command.
When you edit a document using the @command([EditDocument]), the hidden attributes within rich-text
fields are not honored. The hidden attributes are honored when the document is opened in Read mode
with @Command([OpenDocument]).
Language cross-reference
EditDocument method of LotusScript NotesUIWorkspace class
Examples: EditDocument
1. This formula opens the current document in Edit mode.
@Command( [EditDocument]; "1" )
2. This formula toggles the currently open document from Read mode to Edit mode, or vice versa. At
the view level, opens the document in Edit mode.
@Command( [EditDocument] )
3. This formula opens the current document into Edit mode in the preview pane if you are viewing from
the preview pane. This feature is used in Domino.Action.
@Command( [EditDocument]; "1"; "1" )
EditDown @Command
Moves the insertion point in a document down by the number of lines you specify. If you dont specify a
number, moves the insertion point down one line.
or
Parameters
count
Usage
v On a form or subform in Design mode, moves the insertion point down one line or count lines, as if
the user had pressed down.
v In a document in Edit mode, moves the insertion point down within the current field, or if there are no
more lines in the current field, in the next editable field (which must be below, not to the right of, the
current field).
v In a document in Read mode, has no effect.
Language cross-reference
GoToNextField method of LotusScript NotesUIDocument class
Examples: EditDown
This formula moves the insertion point down five lines.
@Command( [EditDown]; "5" )
EditEncryptionKeys @Command
Displays the Properties box for the current document, where you can edit its encryption keys.
Syntax
@Command( [EditEncryptionKeys] )
Usage
v In a view, the user can assign encryption keys to one or more selected documents.
v In a document in Read or Edit mode, the user can assign encryption keys to the current document.
EditFind @Command
Performs the menu command Edit Find/Replace.
Syntax
@Command( [EditFind] )
Language cross-reference
Replace function of LotusScript language
EditFindInPreview @Command
Performs the menu command Edit - Find/Replace without moving the focus to the editing window. This
allows searches to take place when the focus is on the view or folder panes.
Syntax
@Command( [EditFindInPreview] )
Usage
v When the preview pane is opened, displays the Find or Find/Replace dialog box (depending on
whether the user is editing the document in the preview pane or not).
v When the preview pane is not opened, displays the Find dialog box (just as @Command([EditFind])
does).
EditFindNext @Command
Performs the menu command Edit Find Next.
Syntax
@Command( [EditFindNext] )
Usage
The following happens when EditFindNext operates on the result of a full-text search:
v In a view, highlights the next document that contains the search word or phrase.
v In a document, highlights the next occurrence of the search word or phrase.
When EditFindNext is not preceded by a full-text search, Notes displays the Find dialog box.
EditGotoField @Command
In a document in Edit mode, places the insertion point in a field you specify.
Syntax
@Command( [EditGotoField] ; fieldName )
Text. The name of the field where you want to place the insertion point. The field must be editable.
Usage
A document must be open in Edit mode.
EditHeaderFooter @Command
Displays the Properties box for the current document or form, which allows you to set headers, footers,
and other print attributes.
Syntax
@Command( [EditHeaderFooter] )
Usage
v A document must be selected from the view or opened in Read mode
or
v A form or subform must be open in Design mode.
EditHorizScrollbar @Command
Toggles the horizontal scroll bar in a document.
Syntax
@Command( [EditHorizScrollbar] )
Usage
A document must be open.
EditIndent @Command
Indents a paragraph 1/4 inch. The entire paragraph is indented, as well as any paragraphs that are
subsequently typed below it, until the user disables indenting.
Syntax
@Command( [EditIndent] )
Usage
v A form or subform must be open in Design mode
or
v A document must be open in Edit mode, with the insertion point in a rich text field.
Language cross-reference
LeftMargin property of LotusScript NotesRichTextParagraphStyle class
EditIndentFirstLine @Command
Indents the first line of a paragraph 1/4 inch. The first line of the current paragraph is indented, as well
as first lines of subsequently typed paragraphs, until the user disables indenting. (A carriage return
defines a new paragraph.)
Syntax
@Command( [EditIndentFirstLine] )
Usage
v A form or subform must be open in Design mode
or
v A document must be open in Edit mode, with the insertion point in a rich text field.
Language cross-reference
FirstLineLeftMargin property of LotusScript NotesRichTextParagraphStyle class
EditInsertButton @Command
Creates a new button and displays the design pane, where the user can define a formula, simple
action(s), LotusScript, or JavaScript for the button.
Syntax
@Command( [EditInsertButton] )
Chapter 7. Formula Language @Commands A-Z 521
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form or subform must be open in Design mode, with nothing selected.
EditInsertFileAttachment @Command
Attaches a file to a document.
Syntax
@Command( [EditInsertFileAttachment] )
or
Parameters
file
Text. Optional. The name of the file you want to attach. Be sure to include the complete path specification
(appropriate to the users operating system).
compress
Number. Optional. Specify 1 if you want to compress the attachment. Specify 0 if you do not.
Without a file parameter, displays the Create Attachment dialog box. If a file is specified, attaches that file
to the document without opening the Create Attachment dialog box.
Usage
A document must be open in Edit mode with the insertion point in a rich text field.
Language cross-reference
EmbedObject method of LotusScript NotesRichTextItem class
Examples: EditInsertFileAttachment
1. This formula displays the Create Attachment dialog box.
@Command( [EditInsertFileAttachment] )
2. This formula attaches the 123 for Macintosh worksheet Budget96 to the document.
@Command( [EditInsertFileAttachment] ; "Worksheets:Budget96" )
EditInsertObject @Command
Inserts an object into a document, form, or subform.
or
Parameters
object
If an object name is included, Notes assumes it represents a registered OLE object and will attempt to
insert a copy of it into the document or form. If the object name is omitted, Notes displays the Insert
Object dialog box.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form or subform must be open in Design mode.
Language cross-reference
EmbedObject method of LotusScript NotesRichTextItem class
Examples: EditInsertObject
This formula inserts a Word Pro OLE object into the document or form.
@Command( [EditInsertObject] ; "WordPro Document" )
EditInsertPageBreak @Command
Inserts a forced page break into a document, form, subform, or page.
Syntax
@Command( [EditInsertPageBreak] )
Usage
v A document must be open in Edit mode
or
v A form, subform, or page must be open in Design mode.
Language cross-reference
AddPageBreak method of LotusScript NotesRichTextItem class
EditInsertPopup @Command
Creates a hotspot that displays text.
Syntax
@Command( [EditInsertPopup] )
Usage
v A document must be open in Edit mode with text selected in a rich text field
or
v A form, subform, or page must be open in Design mode and text must be selected.
EditInsertTable @Command
Displays the Create Table dialog box, where the user can specify the number of rows and columns in a
new table.
Syntax
@Command( [EditInsertTable] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode, with nothing selected.
Language cross-reference
AppendTable method of LotusScript NotesRichTextItem class
EditInsertText @Command
Inserts the specified string at the current cursor position.
Syntax
@Command( [EditInsertText] ; string )
Parameters
string
Language cross-reference
GotoField method in LotusScript NotesUIDocument class
Examples: EditInsertText
This formula inserts the text Jones, Casey M. at the current position.
@Command( [EditInsertText]; "Jones, Casey M." )
EditLeft @Command
Moves the insertion point in a document, form, subform, or page to the left by the number of spaces you
specify. If you dont specify a number, moves the insertion point one space to the left.
Syntax
@Command( [EditLeft] ; count )
Parameters
count
Usage
v On a form, subform, or page in Design mode, moves the insertion point one or count spaces to the left,
as if the user had pressed the left arrow key.
v In a document in Edit mode, moves the insertion point one or count spaces to the left within the
current field, or if there are no more spaces in the current field, in the previous editable field (which
may be to the left of, or above, the current field).
v In a document in Read mode, has no effect.
Language cross-reference
GoToPrevField method of LotusScript NotesUIDocument class
Examples: EditLeft
This formula moves the insertion point four spaces to the left.
@Command( [EditLeft]; "4" )
EditLinks @Command
Displays the External Links dialog box.
Usage
v A document must be open in Edit mode
or
v A form or subform must be open in Design mode
v The document, form, or subform must contain at least one DDE or OLE link.
Language cross-reference
GetObject method of LotusScript NotesUIDocument class
EditLocations @Command
Opens the Personal Address Book to the Locations view.
Syntax
@Command( [EditLocations] )
Usage
This command does not work on the Web.
EditMakeDocLink @Command
Creates a link to the current document and copies it to the Clipboard. The user can paste the link into
any rich text field.
Syntax
@Command( [EditMakeDocLink] )
Usage
v A document must be selected in a view
or
v A document must be open in Read or Edit mode. A new document must be saved before you can
create a link to it using this command.
After this command is triggered, the status bar displays, DocLink copied to clipboard. Use Paste to
insert it into a document.
Language cross-reference
AppendDocLink method of LotusScript NotesRichTextItem class
EditNextField @Command
In a document in Edit mode, moves the insertion point to the next editable field in the document,
working left to right, top to bottom.
Syntax
@Command( [EditNextField] )
Usage
A document must be open in Edit mode.
Language cross-reference
GoToNextField method of LotusScript NotesUIDocument class
EditOpenLink @Command
Opens the selected link.
Syntax
@Command( [EditOpenLink] )
Usage
This command does not work on the Web.
Language cross-reference
Activate method of LotusScript NotesEmbeddedObject class
EditPaste @Command
Performs the menu command Edit Paste.
Syntax
@Command( [EditPaste] )
Usage
v In a view, pastes in documents that were cut or copied from another database.
v In a document in Edit mode or a form or subform in Design mode, pastes the contents of the
Clipboard into the document, form, or subform. If the data was copied from a rich text field but is
pasted into a nonrich text field, some information may be lost.
v In a document in Read mode, or if the Clipboard is empty, has no effect.
Language cross-reference
Paste method of LotusScript NotesUIDocument class
EditPasteSpecial @Command
Displays the Paste Special dialog box.
Syntax
@Command( [EditPasteSpecial] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form or subform must be open in Design mode.
v If the clipboard is empty, this command has no effect.
EditPhoneNumbers @Command
Displays the Server/Connections view of the Personal Address Book.
Syntax
@Command( [EditPhoneNumbers] )
Usage
This command does not work on the Web.
EditPrevField @Command
In a document in Edit mode, moves the insertion point to the previous editable field in the document,
working right to left, bottom to top.
Syntax
@Command( [EditPrevField] )
Usage
A document must be open in Edit mode.
Language cross-reference
GoToPrevField method of LotusScript NotesUIDocument class
EditProfile @Command
Opens a new or existing profile document in Edit mode.
Parameters
formname
Text. The form upon which the profile is based. Must exist in the database.
uniqueKey
Text. Optional. The unique key that identifies the profile document.
Usage
You can access profile documents quickly and use them to store information that you dont want in user
documents and to share information across scripts within a database.
Only one profile of a given form can exist per database per key. If you create a profile without a key,
Notes assumes its the only profile document of that form in the database. You need at least author access
to create a profile that applies to an entire database.
This function does not work in Web applications. Use @SetProfileField to create a profile document in a
Web application.
Language cross-reference
EditProfile method in LotusScript NotesUIWorkspace class
Examples: EditProfile
1. This formula opens Mary Tsens Interest Profile in a discussion database.
@Command([EditProfile];"Interest Profile";"Mary Tsen/Worksavers/US")
2. This formula creates a Calendar Profile document for the current user or opens the users existing
Calendar Profile.
@Command([EditProfile];"CalendarProfile";@UserName)
3. This formula creates a new Archive Profile document for the current database or opens the Archive
Profile in Edit mode if it already exists.
@Command([EditProfile];"Archive Profile")
4. This formula when used in the Domino Directory opens the Server\Setup Profile document.
@Command([EditProfile];"Profile")
EditProfileDocument @Command
Creates a new or opens an existing profile document in Edit mode.
Parameters
formname
Text. The form upon which the profile is based. Must exist in the database.
uniqueKey
Usage
This command executes immediately. Use the EditProfile @command to execute after all @functions. See
the Order of evaluation for formula statements topic for more details.
You can access profile documents quickly and use them to store information that you dont want in user
documents and to share information across scripts within a database.
Only one profile of a given form can exist per database per key. If you create a profile without a key,
Notes assumes its the only profile document of that form in the database. You need at least author access
to create a profile that applies to an entire database.
This function does not work in Web applications. Use @SetProfileField to create a profile document in a
Web application.
Language cross-reference
EditProfile method in LotusScript NotesUIWorkspace class
EditQuoteSelection @Command
Makes selected text look like an Internet-style reply by prefixing each line with a greater-than sign and
removing attachments and other objects. This sets each line of the message to a default length, preventing
it from wrapping in unexpected places when sent to non-Notes users.
Syntax
@Command( [EditQuoteSelection] )
Usage
A document must be open in Edit mode and text must be selected.
The greater-than sign is the default prefix. You can specify a different prefix with the environment
(notes.ini) variable QuotePrefix.
The default length for wrapping each line is 70. You can specify a different length with the environment
(notes.ini) variable QuoteLineLength.
Examples: EditQuoteSelection
This form action selects and quotes all the text in the current field.
@Command([EditSelectAll]);
@Command([EditQuoteSelection])
EditResizePicture @Command
Displays the proportions of the selected graphic at the bottom of the screen. The user can size the picture
by dragging the mouse in the appropriate direction.
Syntax
@Command( [EditResizePicture] )
Usage
A document must be open in Edit mode and a graphic must be selected.
EditRestoreDocument @Command
Performs the menu command Edit - Restore.
Syntax
@Command( [EditRestoreDocument] )
Usage
In a soft deleted document, restores the document to the view or folder it was deleted from.
In a soft deletions view, restores the selected documents to the folders or views from which they were
deleted.
Examples: @Command([EditRestoreDocument])
1. This code, when used in the Restore action button on a form, enables you to return a document
accessed from a soft deletions view called DeletedDocs to the view or folder that it was deleted
from.
@Command([EditRestoreDocument])
EditRight @Command
Moves the insertion point in a document to the right by the number of spaces you specify. If you dont
specify a number, moves the insertion point one space to the right.
Syntax
@Command( [EditRight] ; count )
Parameters
count
Usage
v On a form or subform in Design mode, EditRight moves the insertion point one or count spaces to the
right, as if the user had pressed RIGHT.
v In a document in Edit mode, EditRight moves the insertion point one or count spaces to the right
within the current field, or if there are no more spaces in the current field, in the next editable field
(which may be to the right of, or below, the current field).
v In a document in Read mode, EditRight has no effect.
Language cross-reference
GoToNextField method of LotusScript NotesUIDocument class
Examples: EditRight
This formula moves the insertion point three spaces to the right.
@Command( [EditRight]; "3" )
EditSelectAll @Command
Performs the menu command Edit Select All.
Syntax
@Command( [EditSelectAll] )
Usage
v In a view or folder, all documents are selected.
v In a document in Read mode, all data on the document is selected, including field labels.
v In a document in Edit mode, all data in the current field is selected.
v On a form or subform, selects everything on the form or subform except layout regions.
Language cross-reference
SelectAll method of LotusScript NotesUIDocument class
EditSelectByDate @Command
Displays the Select by Date dialog box, where the user indicates which documents should be selected in
the view or folder, according to the date they were created or last modified.
Syntax
@Command( [EditSelectByDate] )
Usage
A view or folder must be open.
Language cross-reference
UnprocessedSearch method of LotusScript NotesDatabase class
EditShowHideHiddenChars @Command
Toggles the display of the hidden characters (such as spaces, tabs, and carriage returns) in a document,
form, or subform.
Syntax
@Command( [EditShowHideHiddenChars] ; showOrHide )
Parameters
showOrHide
Number. Optional. Specify 1 if you want to show hidden characters, 0 if you want to hide them. If
you omit this parameter, EditShowHideHiddenChars toggles the current state of the hidden characters.
Language cross-reference
HiddenChars property of LotusScript NotesUIDocument class
EditTableDeleteRowColumn @Command
Displays the Delete Row/Column dialog box, where the user can select the number of rows or columns
to delete from the current table.
Syntax
@Command( [EditTableDeleteRowColumn] )
Usage
v A document must be open in Edit mode
or
v A form, subform, or page must be open in Design mode
v The cursor must be in a table.
Language cross-reference
RemoveRow method of LotusScript NotesRichTextTable class
EditTableFormat @Command
Displays the Properties box for the selected table.
Syntax
@Command( [EditTableFormat] )
Usage
v A document must be open in Edit mode
or
v A form, subform, or page must be open in Design mode
v The cursor must be in a table.
Language cross-reference
AppendStyle method of LotusScript NotesRichTextItem class
Syntax
@Command( [EditTableInsertRowColumn] )
Usage
v A document must be open in Edit mode
or
v A form, subform, or page must be open in Design mode
v The insertion point must be in a table.
Language cross-reference
AddRow method of LotusScript NotesRichTextTable class
EditTop @Command
Moves the insertion point to the top of a document or form.
Syntax
@Command( [EditTop] )
Usage
v On a form in Design mode, EditTop moves the insertion point to the top of the form as if the user had
pressed ctrl+home.
v In a document in Edit mode, EditTop moves the insertion point to the first editable field on the
document.
v In a document in Read mode, EditTop has no effect.
v You can precede this command with either:
@Command([EditDocument]; 1) to put the document into edit mode
@IsDocBeingEdited function to test if the document is in edit mode
Language cross-reference
GotoTop method in LotusScript NotesUIDocument class
EditUndo @Command
Performs the menu command Edit Undo, which undoes the previous reversible operation.
Syntax
@Command( [EditUndo] )
EditUntruncate @Command
Retrieves the full version of a truncated document.
Syntax
@Command( [EditUntruncate] )
Usage
In a database which has undergone replication with the option to receive only summary (truncated)
documents, EditUntruncate retrieves full versions of the truncated documents that you select.
EditUp @Command
Moves the insertion point in a document up by the number of lines you specify. If you dont specify a
number, moves the insertion point up one line.
Syntax
@Command( [EditUp] ; count )
Parameters
count
Usage
v On a form in Design mode, moves the insertion point up one or count lines, as if the user had pressed
up.
v In a document in Edit mode, moves the insertion point up one line within the current field, or if there
are no more lines in the current field, in the previous editable field (which must be above, not to the
right of, the current field).
v In a document in Read mode, has no effect.
v This command does not work on the Web.
Language cross-reference
GoToPrevField method of LotusScript NotesUIDocument class
Examples: EditUp
This formula moves the insertion point up two lines.
@Command( [EditUp];"2" )
Syntax
@Command( [EmptyTrash] )
Usage
This command permanently deletes any documents currently marked for deletion (use MoveToTrash
@Command to mark documents for deletion).
You can use this command with Web applications. The View applet is also programmable via this
@command.
Language cross-reference
ViewRefresh method of LotusScript NotesUIWorkspace class
Examples: @Command([EmptyTrash])
This code, when added as the formula for the Delete action in a view, permanently deletes all the
documents currently marked for deletion in the view.
@Command([EmptyTrash])
ExchangeUnreadMarks @Command
For two selected database replicas, marks the documents as read in one replica that are marked as read in
the other.
Syntax
@Command( [ExchangeUnreadMarks] )
Usage
Two database replicas must be selected whose icons are not stacked.
Execute @Command
Launches an application.
Syntax
@Command( [Execute] ; application ; fileNames )
Parameters
application
Text. A path and file name specifying the application you want to open.
fileNames
Usage
Specify the paths and file names using the appropriate format for the operating system.
Language cross-reference
Shell function of LotusScript language
Examples: Execute
1. This formula launches 123 for Windows.
@Command( [Execute]; "C:\\123W\\PROGRAMS\\123W.EXE" )
2. This formula launches 123 for Windows and loads the worksheet named SALES.WK4.
@Command( [Execute]; "C:\\123W\\PROGRAMS\\123W.EXE"; "C:\\123W\\WORK\\SALES.WK4" )
ExitNotes @Command
Performs the menu command File Exit (File Quit on the Macintosh), which closes Notes/Domino and
all its open windows.
Syntax
@Command( [ExitNotes] )
Usage
This command executes immediately. Use the FileExit @command to execute after all @functions. See the
Order of evaluation for formula statements topic for more details.
This can be used almost anywhere in Notes/Domino except from within a dialog box or on the Web. If
an open document or design element has not been saved, Notes prompts the user to save it.
Language cross-reference
Close method of LotusScript NotesUIDatabase class
FileCloseWindow @Command
Closes the current Notes window. If the document or design element in that window has not been saved,
Notes prompts the user to save it before closing.
Syntax
@Command( [FileCloseWindow] )
Usage
This command executes after all @functions. Use @Command([CloseWindow]) to execute immediately.
See the Order of evaluation for formula statements topic for more details.
You can use this command with Web applications, as long as you enable the Allow Javascript on the
Web setting on the Basics tab of the Database Properties box. Precede this command with
@Command([FileSave]) to simulate a Submit button.
Language cross-reference
Close method of LotusScript NotesUIView class
FileDatabaseACL @Command
Displays the access control list for the current database.
Syntax
@Command( [FileDatabaseACL] )
Usage
A database must be open or selected on the workspace. Although any user with access greater than No
access can view the ACL, only users with Manager access can edit the ACL.
Launguage cross-reference
ACL property in LotusScript NotesDatabase class
FileDatabaseCompact @Command
Compacts the white space in a database, and at the same time, converts the old database to the new
format.
Syntax
@Command( [FileDatabaseCompact] )
Usage
A database must be open, or selected on the workspace. No access level is required to compact a
database.
Language cross-reference
Compact method of LotusScript NotesDatabase class
Examples: @Command([FileDatabaseCompact])
This formula, when added as the code in an action button on a form in the TESTING.NSF database,
compacts the TESTING.NSF database when you click the action button.
@Command([FileDatabaseCompact])
FileDatabaseCopy @Command
Displays the Copy Database dialog box, where the user can copy the current database to a new location.
Syntax
@Command( [FileDatabaseCopy] )
Usage
A database must be open, or selected on the workspace. The user must have at least Reader access to the
database.
Language cross-reference
CreateCopy method of LotusScript NotesDatabase class
FileDatabaseDelete @Command
Permanently deletes the current database file from the hard disk where it is stored.
Syntax
@Command( [FileDatabaseDelete] )
Usage
This command executes after all @functions. Use @Command([DatabaseDelete]) to execute immediately.
See the Order of evaluation for formula statements topic for more details.
A database icon must be selected, but the database cannot be open. The user must have Manager access
in order to delete the database.
Note: To remove the database icon from the users workspace without deleting the database, use
@Command([FileDatabaseRemove]).
Language cross-reference
Remove method of LotusScript NotesDatabase class
FileDatabaseInfo @Command
Displays the Properties box for the current database.
Syntax
@Command( [FileDatabaseInfo] )
Language cross-reference
LotusScript NotesDatabase class
FileDatabaseRemove @Command
Removes the current database icon from the workspace.
Syntax
@Command( [FileDatabaseRemove] )
Usage
The database icon must be selected, but the database cannot be open.
Note: To delete the database file from the hard disk where its stored, use FileDatabaseDelete or
DatabaseDelete.
FileDatabaseUseServer @Command
Displays the Switch Servers dialog box, where the user can choose a server that contains a replica of the
currently selected database.
Syntax
@Command( [FileDatabaseUseServer] )
Usage
The command must be run from the workspace with a database selected.
Language cross-reference
OpenWithFailover method of LotusScript NotesDatabase class
FileExit @Command
Performs the menu command File Exit (File Quit on the Macintosh), which closes Notes/Domino and
all its open windows.
Syntax
@Command( [FileExit] )
This can be used almost anywhere in Notes/Domino except from within a dialog box or on the Web. If
an open document or design element has not been saved, Notes prompts the user to save it.
Language cross-reference
Close method of LotusScript NotesUIDatabase class
FileExport @Command
Exports a Notes/Domino document or view.
Syntax
@Command( [FileExport] )
or
Parameters
fileType
Text. The kind of file you want to export to. See list of file types, below.
fileName
Text. The name of the file you want to export to. Must be a complete path specification, including drive,
directory, and file name.
If the fileType and fileName parameters are omitted, Notes/Domino displays the Export dialog box. If the
parameters are included, Notes/Domino exports the view or currently opened document using the
specified fileType and fileName.
Return value
Number. If the user clicks the Cancel button on the Export dialog box, the number 1 is returned.
Usage
FileExport can be used at the view level, and when a document is open in Read or Edit mode, according
to what is being exported.
The fileType must be one of those listed below. You do not have to spell the name exactly as shown; you
have to include enough characters to uniquely identify the file type. In case of ambiguity, Notes/Domino
will use the first file type in the list that matches your entry.
Note: The Macintosh does not support document level export of the XTND file format (MacWrite II and
Text).
*The formatting of the names of these file types changed with R5.0.5. If you installed (not upgraded to)
R5.0.5 or later, pre-5.0.5 scripts that reference these file types using the old name formats may not work.
Note: With R4.0, Notes does not support exporting ANSI Metafile file types.
Note: With Release 6, Notes does not support exporting UNIX or Lotus Ami Pro file types.
Note: With Release 7, Notes does not support exporting Microsoft Word or WordPerfect file types.
Examples: FileExport
1. This formula exports a view to c:\temp.txt as tabular text.
@Command([FileExport]; "Tabular Text"; "c:\\temp.txt")
2. This formula exports the current view to a 123 for Macintosh worksheet called Hardware and stores
the file in the Lotus 123 folder on the users workstation.
@Command([FileExport];"Lotus 1-2-3";"SBRAUN:Lotus 123:Hardware")
3. This agent formula exports the current document to the testing.txt file on the C drive of the local
machine when the user triggers the agent from the Action menu.
@Command([FileExport];"ASCII";"C:\\testing.txt")
This agent has an event trigger of Action view selection and has None selected as its target.
FileFullTextCreate @Command
Displays the Full-Text Create Index dialog box, where the user can specify settings for the databases
full-text index.
Syntax
@Command( [FileFullTextCreate] )
Usage
This @command takes no parameters.
A database must be open, or selected on the workspace, and the user must have at least Designer access.
Language cross-reference
UpdateFTIndex method of LotusScript NotesDatabase class
Syntax
@Command( [FileFullTextDelete] )
Usage
A database must be open or selected on the workspace, and must have a full-text index already created.
The user must have at least Designer access to the database.
FileFullTextInfo @Command
Displays the Full Text tab of the current databases Properties box.
Syntax
@Command( [FileFullTextInfo] )
Usage
A database must be open, or selected on the workspace.
Language cross-reference
LastFTIndexed property of LotusScript NotesDatabase class
FileFullTextUpdate @Command
Updates full-text indexes for local databases or queues the update request for serverbased databases.
Syntax
@Command( [FileFullTextUpdate] )
Usage
A database must be open, or selected on the workspace.
Language cross-reference
UpdateFTIndex method of LotusScript NotesDatabase class
FileImport @Command
Imports a file into a Notes/Domino document or view.
Parameters
fileType
Text. The kind of file you want to import. See list of file types, below.
fileName
Text. The name of the file you want to import. Must be a complete path specification, including drive,
directory, and file name.
If the fileType and fileNameparameters are omitted, this displays the Import dialog box. If the parameters
are included, Notes/Domino imports the specified file into the currently open document, or into a view.
Usage
FileImport can be used at the view level, and when a document is open in Edit mode, according to what
is being imported. If the document is being edited, the insertion point must be in a rich text field.
The fileTypemust be one of those listed below. You do not have to spell the name exactly as shown; you
have to include enough characters to uniquely identify the file type. In case of ambiguity, Notes/Domino
will use the first file type in the list that matches your entry.
Note: The Macintosh does not support document-level import of the XTND file format (MacWrite II and
Text).
*The formatting of the names of these file types changed with R5.0.5. If you installed (not upgraded to)
R5.0.5 or later, pre-5.0.5 scripts that reference these file types using the old name formats may not work.
Note: With R4.0, Notes does not support importing ANSI Metafile file types.
Note: With Release 6, Notes does not support importing UNIX or Ami Pro file types.
Language cross-reference
Import method in LotusScript NotesUIDocument class
FileNewDatabase @Command
Displays the New Database dialog box, where the user can select a server, title, and file name for a new
database.
Syntax
@Command( [FileNewDatabase] )
Usage
This command does not work on the Web.
Language cross-reference
Create method of LotusScript NotesDatabase class
FileNewReplica @Command
Displays the New Replica dialog box, where the user can create a replica of the current database.
Syntax
@Command( [FileNewReplica] )
Usage
This command does not work on the Web.
Language cross-reference
CreateReplica method of LotusScript NotesDatabase class
FileOpenDatabase @Command
Opens the specified database to the specified view, highlighting the first document whose value in the
sort column matches the key. You specify a database using its server and file name.
Syntax
@Command( [FileOpenDatabase]; server : database ; viewName ; key ; newinstance ; temporary )
or
database
Text. Optional. The path and file name (in the appropriate format for the operating system) of the
database you want to open. If you omit the name of the database, and one is already open,
Notes/Domino displays that databases view in the topmost, or current, window. If no database is open
but one is selected on the workspace, the selected database is opened. If no databases are open or
selected, Notes/Domino displays the Open Database dialog box, so the user can select a database.
viewName
Text. Optional. The name of the view you want to open in the database. If you omit the name of the
view, the database opens to its default view; or, if the user has opened the database before, to the last
view used by that user.
key
Text. Optional. Indicates which document you want Notes to scroll to when it opens viewName.The key is
a value that appears in the first sorted column of viewName. If you omit the key, no document is selected.
newinstance
Number. Optional. Specify 1 if you want the view to open in a new window, even if the database is
already open in that view. If you omit this parameter, the new window is opened only if the database is
opened in a new view.
temporary
Number. Optional. Specify 1 if you only want the database opened on a temporary basis for browsing,
without adding the database to the users workspace. If you omit this parameter, the database is added to
the users workspace.
navigator
Text. Optional. The name of a navigator defined for the database. On opening the database, Notes
displays this navigator.
solo
Number. Optional. A value of 1 instructs Notes/Domino to open the navigator named by navigator in
its own window.
Usage
If you omit some of the parameters like viewName and key, but still include the parameters that come
after it, substitute for each parameter that youre skipping, as in:
@Command([FileOpenDatabase]; "Sales":"PROBLEMS.NSF"; ""; ""; ""; "1" )
You can use this command in Web applications, but the server argument must be specified as a null string
(). When using the view argument, you must follow the command with @Command [OpenDocument].
Examples: FileOpenDatabase
1. Notes/Domino opens the PROBLEMS.NSF database, which is stored on the Development server. If
the database is already open, Notes/Domino brings that window to the foreground. If the database is
not open, Notes/Domino opens it in a new window. Since no view was specified, the database opens
either to the default view, or if the user has opened the database before, to the view last used by the
user. If the database is not on the users workspace, it will be added automatically.
@Command([FileOpenDatabase];"Development":"PROBLEMS.NSF")
2. Notes/Domino opens the PROBLEMS.NSF database on the Development server. Additionally,
Notes/Domino opens a new window, displays the Open Problem Reports view, and highlights the
first document containing Printer problems in the key field. Since the temporary parameter is used,
the database icon is not added to the users workspace.
@Command([FileOpenDatabase]; "Development":"PROBLEMS.NSF"; "Open Problem Reports"; "Printer
problems"; "1"; "1" )
3. This code, when added to the Open My Feedback hotspot button returns the All\By Employee view
of the UserNotes.nsf database located in the feedback subdirectory of the Customers/ME/ACME
server. The view, which contains documents grouped by category, where the categories are employee
names appears with the category named after the current user highlighted and displayed in the first
row of the view.
@Command([FileOpenDatabase]; "Customer/ME/ACME" : "feedback\\UserNotes.nsf" ; "All\\By Employee" ;
@Name([CN];@UserName(0)) ; "1" ; "1")
4. This formula, when added to the Intl hotspot button on a document whose design is based on the
USUser form, opens the Intl view. If the Intl views form formula is IntlUser, the user can select the
same document from this view and it will display using the IntlUser form. If you do not close the
current USUser-based document first, it will redisplay based on the USUser form when selected from
the Intl view.
@Command([CloseWindow]);
@Command([FileDatabaseOpen];"AcmeServer/Central";"Users.nsf";"Intl")
FileOpenDBRepID @Command
Opens the specified database to the specified view, highlighting the first document whose value in the
sort column matches the key. You specify a database using its replica ID, and Notes/Domino searches the
workspace and all servers available in the current session to find a replica.
Syntax
@Command( [FileOpenDBRepID] ; replicaID ; serverHint ; viewName ; key ; newInstance ; temporary )
or
Text. The replica ID of the database you want to open. You can see the replica ID for a database in its
InfoBox.
serverHint
Text. Optional. The name of a server where the database might reside. Notes/Domino checks this server
for the replica before checking other servers only if the database was not accessible from a workspace
icon.
viewName
Text. Optional. The name of the view that you want to open in the database. If you omit the name of the
view, the database opens to its default view, or if the user has opened the database before, to the last
view used by that person.
key
Text. Optional. Indicates which document you want Notes/Domino to scroll to when it opens
viewName.The key is a value that appears in the first sorted column of viewName. If you omit the key, no
document is selected.
newInstance
Number. Optional. Specify 1 if you want the view to always open in a new window, even if theres
already a window open for the database. Specify an empty string () if you want the new window
opened only when its actually needed.
temporary
Number. Optional. Specify 1 if you want the database opened on a temporary basis for browsing,
without adding the database to the users workspace. Specify an empty string () if you want to add the
database to the users workspace.
navigator
Text. Optional. The name of a navigator defined for the database. On opening the database, Notes
displays this navigator.
solo
Number. Optional. A value of 1 instructs Notes to open the navigator named by navigator in its own
window.
Usage
FileOpenDBRepID is useful whenever you want to write a formula for users working on several different
replicas of the same database. Libraries, for example, use this command to open a database from the
library.
Language cross-reference
OpenByReplicaID method of LotusScript NotesDatabase class
Examples: FileOpenDBRepID
This formula opens the first database that Notes/Domino finds with the replica ID 85255F1E:004F2CEB,
to the All by Category view.
@Command( [FileOpenDBRepID] ; "85255F1E:004F2CEB";
""; "All by Category" )
FilePageSetup @Command
Displays the Page Setup dialog box (or, on the Macintosh, the File Print Margins dialog box), which
allows you to specify print settings for the selected database.
Syntax
@Command( [FilePageSetup] )
Usage
A database must be selected or open.
Language cross-reference
Print method in LotusScript NotesUIDocument class
FilePrint @Command
Prints the currently open or selected document(s), or the current view.
Syntax
@Command( [FilePrint] )
or
@Command( [FilePrint] ; numCopies ; fromPage ; toPage ; ifDraft ; ifView ; formName ; breakType ; ifReset;
startDate; endDate )
Parameters
numCopies
Text. Optional. The string must evaluate to a number, or be empty. The number of copies you want to
print. Specify an empty string () for one copy.
fromPage
toPage
Text. Optional. The string must evaluate to a number, or be empty. The page of a document where you
want to stop printing. Specify an empty string () if you want to print all pages.
ifDraft
Text. Optional. Either the word draft, to indicate that you want draft quality printing; or an empty
string (), if you want regular quality printing.
ifView
Text. Optional. Either the word printview, to indicate that you want to print the current view; or an
empty string (), if you want to print the selected document(s) in a view, not the view itself. This
parameter is ignored if youre printing from an open document.
formName
Text. Optional. The name of the form you want to use to print the document. Specify an empty string ()
if you want to print the document using its current form. This parameter is ignored if youre printing
from an open document.
breakType
Text. Optional. Either the word pagebreak, the word line, or an empty string (). If youre printing
multiple documents from a view, pagebreakindicates you want a page break between each document,
line indicates you want a ruled line between each document, and an empty string indicates you want a
blank line between each document. This parameter is ignored if youre printing from an open document.
ifReset
Text. Optional. Either the word resetpages, or an empty string (). If youre printing multiple
documents from a view, then resetpages specifies that page numbering begins at 1 with each new
document; and an empty string () specifies that page numbering begins at 1 with the first document
and continues cumulatively. This parameter is ignored if youre printing from an open document.
startDate
Time-date. Optional. Used with the printview parameter when printing a calendar view; indicates the first
date to be printed. Specify an empty string () if you want to start printing with the earliest date in the
view.
endDate
Time-date. Optional. Used with the printview parameter when printing a calendar view; indicates the last
date to be printed. Specify an empty string () if you want to end printing with the last date in the view.
Usage
With no parameters, FilePrint displays the File Print dialog box (on the Macintosh, the chosen printers
dialog box). With parameters, FilePrint prints the current document(s) or view without displaying the
dialog box.
This @command does not work on the Web. Use the browsers print button to print the current document
or view. All hide-when formulas set for elements in the form or view are invoked by the browser.
Language cross-reference
Print method in LotusScript NotesUIDocument class
FilePrintSetup @Command
Displays the Print Setup dialog box, which allows you to direct the current view or document to a printer
or a file that you specify.
Note: [FilePrintSetup] is not supported on the Macintosh. To make setup changes, use [FilePrint]; to
select different printers, use the Chooser.
Syntax
@Command( [FilePrintSetup] )
Usage
A database must be open to a view or to a document.
Language cross-reference
Print method in LotusScript NotesUIDocument class
FileSave @Command
Performs the menu command File Save.
Syntax
@Command( [FileSave] )
A form, subform, view, folder, agent, or navigator must be open in Design mode.
You can use this command with Web applications, as long as you enable the Web access: Use JavaScript
when generating pages setting on the Basics tab of the Database Properties box. Follow this command
with @Command([FileCloseWindow]) or @Command([CloseWindow]) to simulate a Submit button.
Language cross-reference
Save method of LotusScript NotesDocument class
Examples: FileSave
1. This code, when added to the Next action button in form1 and triggered from the Notes client,
saves and closes form1 and opens form2 in edit mode.
dbname := @DbName;
@Command([FileSave]);
@Command([CloseWindow]);
@Command([Compose]; dbname; "form2")
2. This code, when added to the Save action button in a form and triggered from Notes, saves the
current document and opens the AllDocs view when the save is successful. If the save is not
successful, it returns the message, Save unsuccessful, to the status bar.
@If(@Command([FileSave]);@Do(@Command([CloseWindow]);@Command([OpenView];"AllDocs"));@StatusBar
("Save unsuccessful"))
FileSaveNewVersion @Command
Saves a document as a new version.
Syntax
@Command( [FileSaveNewVersion] )
Usage
A document must be open in Edit mode.
Language cross-reference
SaveNewVersion method in LotusScript NotesUIDocument class
FindFreeTimeDialog @Command
Opens the Free Time dialog box to allow searches for available meeting times.
Syntax
reqPeopleItems
Text or text list. Names of fields (items) in the current document that contain names of people required at
the meeting.
optPeopleItems
Text or text list. Optional. Names of fields (items) in the current document that contain names of people
whose attendance is optional.
reqRoomsItems
Text or text list. Optional. Names of fields (items) in the current document that contain names of rooms
required for the meeting.
optRoomsItems
Text or text list. Optional. Names of fields (items) in the current document that contain names of optional
rooms.
reqResourcesItems
Text or text list. Optional. Names of fields (items) in the current document that contain names of
resources required for the meeting.
optResourcesItems
Text or text list. Optional. Names of fields (items) in the current document that contain names of optional
resources.
removedPeopleItems
Text or text list. Optional. Names of fields (items) in the current document that contain names of people
to remove from the attendance list.
startDateTime
Text. Name of a Time field (item) in the current document that contains the start time for the meeting.
You must specify the start date time.
endDateTime
Text. Name of a Time field (item) in the current document that contains the end time for the meeting. You
must specify the end date time.
Usage
v If you dont need a parameter, use consecutive quotes () to omit it.
v The meeting time should not span midnight.
v The user can adjust the values specified here through the dialog box.
Examples: FindFreeTimeDialog
This @command opens the Free Time dialog box with required people from the From and SendTo fields
in the current document, and times from the StartDateTime and EndDateTime fields.
@Command([ViewRefreshFields]);
@Command([FindFreeTimeDialog]; "From" : "SendTo"; ""; ""; ""; ""; ""; ""; "StartDateTime"; "EndDateTime")
Folder @Command
Moves or copies the selected document to a folder.
Syntax
@Command( [Folder] ; folderName ; moveOrCopy )
Parameters
folderName
Text. Optional. The name of the folder to which you want to move or copy the selected document. If you
omit this parameter, Notes/Domino displays the Move to Folder dialog box, where you can choose a
folder.
moveOrCopy
Number (1 or 0). Optional. A value of 1 moves the document to the folder. A value of 0 copies the
document to the folder. If you omit this parameter, Folder assumes a value of 0 (copy).
If you include moveOrCopy with a value of 0 but omit folderName,Notes/Domino displays the Move to
Folder dialog box with the Move button dimmed. If you include moveOrCopy with a value of 1 but omit
folderName,Notes/Domino displays the Move to Folder dialog box with all of its options available.
Usage
This command executes after all @functions. Use the FolderDocuments @Command to execute
immediately. See the Order of evaluation for formula statements topic for more details.
If you dont want to specify a folderName, but you want to specify a moveOrCopy, use a NULL string as
shown below.
@Command([Folder];"";"1")
Folder does not work for new documents. If multiple documents are selected in a view, they are all
moved or copied to the folder.
@AddToFolder works just like @Command([Folder]; Foldername; MoveOrCopy) except it can move a
document from another folder.
This @command works on the Web if Use applet in the browser is in effect for the implementing view
or folder.
FolderCollapse @Command
For a folder or view containing nested folders or views, collapses the selected folder or view in the
navigation pane.
Syntax
@Command( [FolderCollapse] )
Usage
A database must be open to a view or folder. Focus must be in the navigation pane.
FolderCustomize @Command
Displays the design pane for the currently selected view or folder.
Syntax
@Command( [FolderCustomize] )
Usage
A database must be open to a view or folder.
FolderDocuments @Command
Moves or copies the selected document to a folder.
Syntax
@Command( [FolderDocuments] ; folderName ; moveOrCopy )
Parameters
folderName
Text. Optional. The name of the folder to which you want to move or copy the selected document. If you
omit this parameter, Notes/Domino displays the Move to Folder dialog box, where you can choose a
folder.
moveOrCopy
Number (1 or 0). Optional. A value of 1 moves the document to the folder. A value of 0 copies the
document to the folder. If you omit this parameter, Folder assumes a value of 0 (copy).
Usage
This command executes immediately. Use the Folder @command to execute after all @functions. See the
Order of evaluation for formula statements topic for more details.
If you dont want to specify a folderName, but you want to specify a moveOrCopy, use a NULL string as
shown below.
@Command([FolderDocuments];"";"1")
Folder does not work for new documents. If multiple documents are selected in a view, they are all
moved or copied to the folder.
This @command works on the Web if Use applet in the browser is in effect for the implementing view
or folder.
Language cross-reference
Folder method of LotusScript NotesUIWorkspace class
FolderExpand @Command
Expands the currently selected view or folder one level in the navigation pane.
Syntax
@Command( [FolderExpand] )
Usage
A database must be open to a view or folder. Focus must be in the navigation pane.
FolderExpandAll @Command
Fully expands all views and folders in the navigation pane.
Syntax
@Command( [FolderExpandAll] )
FolderExpandWithChildren @Command
Fully expands the selected view or folder in the navigation pane.
Syntax
@Command( [FolderExpandWithChildren] )
Usage
A database must be open to a view or folder. Focus must be in the navigation pane.
FolderMove @Command
Displays the Move dialog box for a view or folder, which allows you to move the selected view or folder.
Syntax
@Command( [FolderMove] )
Usage
A database must be open to a view or folder.
To move documents to a folder, see the FolderDocuments, Folder, ChooseFolders @commands or the
@AddToFolder function.
FolderProperties @Command
Displays the Properties box for a view or folder.
Syntax
@Command( [FolderProperties] )
Usage
A view or folder must be open in Design mode. Focus must be in the navigation pane.
Language cross-reference
LotusScript NotesView class
FolderRename @Command
Displays the Rename dialog box, which allows you to rename the selected folder or view.
Usage
A database must be open to a view or folder.
Language cross-reference
Name property of LotusScript NotesView class
FormActions @Command
Displays the actions pane for the current form, subform, or Page. The command is a toggle; selecting it
again hides the actions pane.
Syntax
@Command( [FormActions] )
Usage
A form, subform, or Page must be open in Design mode.
FormTestDocument @Command
Creates a document using the current form or Page, so you can test its fields, formulas, and scripts.
Syntax
@Command( [FormTestDocument] )
Usage
A form or Page must be open in Design mode. This command does not work for subforms. This
command does not work on the Web.
GoUpLevel @Command
Displays the view containing the current document when the user closes that document.
Syntax
@Command( [GoUpLevel] )
Usage
If you open a document by activating a link, use GoUpLevel to display the view in which that document
appears rather than close the database when you close the document.
Language cross-reference
CurrentView property of LotusScript NotesUIWorkspace class
Syntax
@Command( [HelpAboutDatabase] )
Usage
This can be used anywhere in Notes/Domino, provided a database is open or selected on the workspace.
For more on creating About This Database documents, see Creating About and Using documents for a
database in the Application Development with Domino Designerguide.
HelpAboutNotes @Command
Displays the Notes splash screen that appears when you launch Notes/Domino. The screen displays the
current release number and date.
Syntax
@Command( [HelpAboutNotes] )
Usage
This command does not work on the Web.
HelpUsingDatabase @Command
Displays the Using This Database document for the current database. The Using This Database document
typically provides pointers on how to use an applications forms and views.
For more information on database help documents, see Creating About and Using documents for a
database in the Application Development with Domino Designer book.
Syntax
@Command( [HelpUsingDatabase] )
Usage
This can be used anywhere in Notes/Domino, provided a database is open or selected on the workspace.
This command does not work on the Web.
HotspotClear @Command
Removes a hotspot, without deleting the underlying text or graphic.
Syntax
@Command( [HotspotClear] )
Language cross-reference
Remove method of LotusScript NotesEmbeddedObject class
HotspotProperties @Command
Displays the Properties box for the current hotspot.
Syntax
@Command( [HotspotProperties] )
Usage
v A document must be open in Edit mode
or
v A form or subform must be open in Design mode.
v The cursor must be within a hotspot.
Language cross-reference
LotusScript NotesEmbeddedObject class
InsertSubform @Command
Displays the Insert Subform dialog box, where you can select a subform to be inserted on a form.
Syntax
@Command( [InsertSubform] )
Usage
A form must be open in Design mode. There must be at least one subform in the database.
LayoutAddGraphic @Command
Adds a graphic from the Clipboard to a layout region.
Usage
A form or subform must be open in Design mode, a layout region must be selected, and the graphic you
want to add must be on the Clipboard.
LayoutAddText @Command
Creates a static text box in a layout region.
Syntax
@Command( [LayoutAddText] )
Usage
A form or subform must be open in Design mode and a layout region must be selected.
LayoutElementBringToFront @Command
Brings the selected layout element to the front, which means it displays on top of any other layout
elements that overlap it.
Syntax
@Command( [LayoutElementBringToFront] )
Usage
A form or subform must be open in Design mode, and an element within a layout region must be
selected.
LayoutElementProperties @Command
Displays the Properties box for the currently selected layout element.
Syntax
@Command( [LayoutElementProperties] )
Usage
A form or subform must be open in Design mode, and an element within a layout region must be
selected.
LayoutElementSendToBack @Command
Sends the selected layout element to the back, which means it displays underneath any other layout
elements that overlap it.
Usage
A form or subform must be open in Design mode and an element within a layout region must be
selected.
LayoutProperties @Command
Displays the Properties box for the currently selected layout region.
Syntax
@Command( [LayoutProperties] )
Usage
A form or subform must be open in Design mode and a layout region (or an element within it) must be
selected.
MailAddress @Command
Displays the Mail Address window, where the user can select people and groups to include in an address
field of a mail document.
Syntax
@Command( [MailAddress] )
Usage
For MailAddress to execute successfully, a mail document must be open in Edit mode, and the insertion
point must be in an editable field.
The dialog box that displays is a dialog resource built into the core Notes program components, but it is
based on the ($PeopleGroupsFlat) view in the local Address book or the server directory, depending on
which is selected for use.
Examples: @Command([MailAddress])
This formula, when added to the Address action button on the Memo form in a mail database,
displays the Select Addresses dialog box when an editable field is selected and the Address action
button is clicked. A user can select addresses from his or her address books and Notes populates the
editable field with the addresses selected.
@Command([MailAddress])
MailComposeMemo @Command
Creates and displays a blank mail document. Notes/Domino uses the default form for the users mail
database. This is a Memo document unless the user has changed it.
Usage
This command can be used almost anywhere in Notes/Domino except from within a dialog box or on
the Web.
Examples: @Command([MailComposeMemo])
1. This formula, when used in a hotspot button named Create Memo, opens a new mail memo in edit
mode.
@Command([MailComposeMemo])
MailForward @Command
Forwards the current document by placing its contents into a mail memo, which the user then addresses
and sends like any other mail memo.
Syntax
@Command( [MailForward] )
Usage
A document must be open in Read or Edit mode, or selected in a view or folder. If multiple documents
are selected, the contents of each selected document are placed into the mail memo.
Language cross-reference
Forward method in LotusScript NotesUIDocument class
MailForwardAsAttachment @Command
In cc:Mail, forwards a Notes/Domino document as a cc:Mail attachment.
Syntax
@Command( [MailForwardAsAttachment] )
Usage
This command does not work on the Web.
MailOpen @Command
Opens the users mail database to the view or navigator to which it was most recently open.
Syntax
@Command( [MailOpen] )
Usage
This command does not work on the Web.
MailRequestCrossCert @Command
Displays the Choose ID to be Cross-Certified dialog box, which allows an administrator to send a safe
copy of a Certifier ID to another administrator, who can certify it with a different Certifier ID to create a
cross certificate.
Syntax
@Command( [MailRequestCrossCert] )
Usage
This can be used almost anywhere in Notes/Domino except from within a dialog box or on the Web.
Language cross-reference
CrossCertify method of LotusScript NotesRegistration class
MailRequestNewName @Command
Displays the Change User Name dialog box, which allows the user to send a portion of the Notes user ID
to a Notes/Domino administrator, who can change the user name associated with the ID and return the
ID to the user. The user then merges the updated portion back into the existing user ID.
Syntax
@Command( [MailRequestNewName] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box.
MailRequestNewPublicKey @Command
Displays the Mail New Public Key Request dialog box, which allows the user to send a portion of his or
her Notes/Domino ID to an administrator, who can create a new public key for the ID and return the ID
to the user. The user then merges the updated portion back into the existing user ID.
Syntax
@Command( [MailRequestNewPublicKey] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. The users ID file must be
certified by a hierarchical certifier.
Syntax
@Command( [MailScanUnread] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box.
MailSend @Command
Displays the Mail Send dialog box, which lets the user choose whether or not to encrypt, sign, or send
the selected memo.
Syntax
@Command( [MailSend] )
Usage
A document must be open in read or Edit mode, or selected in a view. The document must contain a
SendTo field, indicating the documents recipients.
Language cross-reference
LotusScript NotesDocument class
MailSendCertificateRequest @Command
Displays the Mail Certificate Request dialog box. This lets the user send a safe copy of the Notes/Domino
user ID to an administrator, who certifies and then returns it; the user then merges the updated safe copy
back into the user ID.
Syntax
@Command( [MailSendCertificateRequest] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box.
MailSendEncryptionKey @Command
Displays the User ID dialog box, where the user can define and send encryption keys. If the users ID is
passwordprotected, the user will be required to enter the password before being allowed access to the
dialog box.
Usage
This can be used anywhere in Notes/Domino except from within a dialog box.
MailSendPublicKey @Command
Displays the Mail Public Key dialog box. This lets the user send the public key to another user (typically
to an administrator who can then paste the public key into that users Person record in the Domino
Directory).
Syntax
@Command( [MailSendPublicKey] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box.
MoveToTrash @Command
Marks the currently selected document for deletion.
Syntax
@Command( [MoveToTrash] )
Usage
The View applet is programmable via this @Command.
This command does not permanently delete documents; it marks them for deletion. To permanently
delete the documents marked for deletion, the user must refresh the view manually, or programmatically
using any function that refreshes the view, such as the ViewRefreshFields @command. A user can also
permanently delete documents marked for deletion by triggering the EmptyTrash @command.
MoveToTrash has the same functionality as selecting a document in a view and pressing the Delete key.
You can toggle both. Just as you can remove the deletion mark from a selected document in a view by
pressing the Delete key a second time, if you trigger the MoveToTrash command a second time, the mark
for deletion is removed from the document.
Language cross-reference
DeleteDocument method of LotusScript NotesDocumentCollection class
Tip: To permanently delete the documents now marked for deletion, call @Command([EmptyTrash]) after
this command.
NavigateNext @Command
Navigates to the next document in the current view or folder.
Syntax
@Command( [NavigateNext] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes after all @functions. Use @Command([NavNext]) to execute immediately. See the
Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions. For instance,
if you have a view template form associated with a specific view, and want a Web user to be able to
jump to the next document in a document list without having to return to the view to select it, add this
command as an action or hotspot to the original form associated with the view, not to the view or view
template form. See Designing a form as a view or navigator template in the Application Development with
Domino Designer guide for details on view template forms.
Language cross-reference
GetNextDocument method of LotusScript NotesView class
Examples: NavigateNext
1. This example, when added as an action to a form, enables a Web user to jump to the next document
in a view without having to return to the view to select the next document from the view list:
@Command([NavigateNext])
NavigateNextHighlight @Command
Navigates to the next full-text search highlight within a document, working from left to right and top to
bottom.
Syntax
@Command( [NavigateNextHighlight] )
NavigateNextMain @Command
Navigates to the next main document in the current view.
Syntax
@Command( [NavigateNextMain] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes after all @functions. Use @Command([NavNextMain]) to execute immediately.
See the Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions.
Language cross-reference
GetNextCategory method of LotusScript NotesViewNavigator class
NavigateNextSelected @Command
Navigates to the next selected document in the current view or folder.
Syntax
@Command( [NavigateNextSelected] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes after all @functions. Use @Command([NavNextSelected]) to execute immediately.
See the Order of evaluation for formula statements topic for more details.
Language cross-reference
GetNextDocument method of LotusScript NotesDocumentCollection class
Syntax
@Command( [NavigateNextUnread] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes after all @functions. Use NavNextUnread to execute immediately. See the Order
of evaluation for formula statements topic for more details.
NavigatePrev @Command
Navigates to the previous document in the current view or folder.
Syntax
@Command( [NavigatePrev] )
Usage
v A database must be open at the view level
or
v A document can be open in Read or Edit mode
This command executes after all @functions. Use @Command([NavPrev]) to execute immediately. See the
Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions. For instance,
if you have a view template form associated with a specific view, and want a Web user to be able to
jump to the previous document in a document list without having to return to the view to select it, add
this command as an action or hotspot to the original form associated with the view, not to the view or
view template form. See Designing a form as a view or navigator template in the Application Development
with Domino Designer guide for details on view template forms.
Language cross-reference
GetPrevDocument method of LotusScript NotesViewNavigator class
Examples: NavigatePrev
1. This example, when added as an action to a form, enables a Web user to jump to the previous
document in a view without having to return to the view to select the previous document from the
view list:
570 Prgramming Guide, Volume 1: Overview and Formula Language
@Command([NavigatePrev])
NavigatePrevHighlight @Command
Navigates to the previous full-text search highlight within a document, working from right to left and
bottom to top.
Syntax
@Command( [NavigatePrevHighlight] )
Usage
The document must be open in Read or Edit mode and the highlight must already be moved past the
first highlighted occurrence.
NavigatePrevMain @Command
Navigates to the previous main document in the current view or folder.
Syntax
@Command( [NavigatePrevMain] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes after all @functions. Use @Command([NavPrevMain]) to execute immediately.
See the Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions.
Language cross-reference
GetPrevCategory method of LotusScript NotesViewNavigator class
NavigatePrevSelected @Command
Navigates to the previous selected document in the current view or folder.
Syntax
@Command( [NavigatePrevSelected] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
Language cross-reference
GetPrevDocument method of LotusScript NotesDocumentCollection class
NavigatePrevUnread @Command
Navigates to the previous unread document in the current view or folder.
Syntax
@Command( [NavigatePrevUnread] )
Usage
This command executes after all @functions. Use @Command([NavPrevUnread]) to execute immediately.
See the Order of evaluation for formula statements topic for more details.
A database must be open at the view or folder level, or a document can be open in Read or Edit mode.
NavigateToBacklink @Command
Returns to the document from which you launched the current document.
Syntax
@Command( [NavigateToBacklink] )
Usage
When you open a document, launch another document from it by activating a link, and then close the
second document, NavigateToBack link closes the database containing the second document and returns
to the first document.
Language cross-reference
GetPrevDocument method of LotusScript NotesView class
NavigatorProperties @Command
Displays the Properties box for a navigator.
Syntax
@Command( [NavigatorProperties] )
NavigatorTest @Command
Opens a navigator in Testing mode, so you can test its hotspots, formulas, and scripts. Selecting this
command again puts the navigator back into Design mode.
Syntax
@Command( [NavigatorTest] )
Usage
A navigator must be open in Design mode.
NavNext @Command
Navigates to the next document in the current view or folder.
Syntax
@Command( [NavNext] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigateNext @command to execute after all @functions.
See the Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions. For instance,
if you have a view template form associated with a specific view, and want a Web user to be able to
jump to the next document in a document list without having to return to the view to select it, add this
command as an action or hotspot to the original form associated with the view, not to the view or view
template form. See Designing a form as a view or navigator template in the Application Development with
Domino Designer guide for details on view template forms.
Language cross-reference
GetNextDocument method of LotusScript NotesView class
Syntax
@Command( [NavNextMain] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigateNextMain @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions.
Language cross-reference
GetNextCategory method of LotusScript NotesViewNavigator class
NavNextSelected @Command
Navigates to the next selected document in the current view or folder.
Syntax
@Command( [NavNextSelected] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigateNextSelected @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
Language cross-reference
GetNextDocument method of LotusScript NotesDocumentCollection class
Syntax
@Command( [NavNextUnread] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigateNextUnread @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
NavPrev @Command
Navigates to the previous document in the current view or folder.
Syntax
@Command( [NavPrev] )
Usage
v A database must be open at the view level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigatePrev @command to execute after all @functions.
See the Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions. For instance,
if you have a view template form associated with a specific view, and want a Web user to be able to
jump to the previous document in a document list without having to return to the view to select it, add
this command as an action or hotspot to the original form associated with the view, not to the view or
view template form. See Designing a form as a view or navigator template in the Application Development
with Domino Designer guide for details on view template forms.
Language cross-reference
GetPrevDocument method of LotusScript NotesViewNavigator class
Syntax
@Command( [NavPrevMain] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigatePrevMain @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
For Web applications, use this command only for forms. It does not work for view actions.
Language cross-reference
GetPrevCategory method of LotusScript NotesViewNavigator class
NavPrevSelected @Command
Navigates to the previous selected document in the current view or folder.
Syntax
@Command( [NavPrevSelected] )
Usage
v A database must be open at the view or folder level
or
v A document can be open in Read or Edit mode
This command executes immediately. Use the NavigatePrevSelected @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
Language cross-reference
GetPrevDocument method of LotusScript NotesDocumentCollection class
Syntax
@Command( [NavPrevUnread] )
Usage
This command executes immediately. Use the NavigatePrevUnread @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
A database must be open at the view or folder level, or a document can be open in Read or Edit mode.
ObjectDisplayAs @Command
Displays the Display As dialog box, which lets you change the display settings of the selected OLE object.
Syntax
@Command( [ObjectDisplayAs] )
Usage
An OLE object must be selected.
ObjectOpen @Command
Opens an OLE object for editing.
Syntax
@Command( [ObjectOpen] )
Usage
An OLE object must be selected.
Language cross-reference
Activate method of LotusScript NotesEmbeddedObject class
Syntax
@Command( [ObjectProperties] )
Usage
This command does not work on the Web.
Language cross-reference
LotusScript NotesEmbeddedObject class
OpenCalendar @Command
Opens a mail file to the Calendar view.
Syntax
@Command( [OpenCalendar]; username )
Parameter
username
Usage
If you specify username, this command opens the mail file of that user. If you omit username, this
command displays the name picker dialog, then opens the mail file of the selected user. This command
temporarily adds the icon for the mail database to the workspace.
Language cross-reference
OpenView method of LotusScript NotesUIDatabase class
OpenDocument @Command
Opens a document.
Syntax
@Command( [OpenDocument] ; writeOrReadOnly ; UNID ; width : height)
Parameters
writeOrReadOnly
Text (1 or 0). Optional. A value of 1 opens the document in Edit mode. A value of 0 (the default)
opens the document in Read-only mode.
UNID
width : height
Number list. Optional. The width and height, in inches, of the window for the document you open. If
you omit this parameter or use zero for either value, you create the window at the default size (usually
the size that the last user set).
Note: The width and height parameters have no effect in Release 5 and later.
Usage
A database must be open to a document view and the view must contain the document you want to
open.
The width-height parameter does not apply in MDI mode when the window is maximized. When
restored, the window returns to the size you specify. The measurement in inches matches the ruler bar in
the editor, so you can use the ruler bar to guide you in sizing the window. When you specify the width
and height, you center the window in the enclosing Notes/Domino window (for MDI mode) or in the
operating desktop (for Mac and SDI mode).
You can use this command in Web applications, but it must be used in conjunction with
@Command([FileOpenDatabase]) or @Command ([OpenView]). You can use the URL command to open a
document by its UNID; see the URL commands for opening documents by key section of the Application
Development with Domino Designer guide.
Language cross-reference
EditDocument method of LotusScript NotesUIWorkspace class
Examples: OpenDocument
1. This formula opens the selected document in Read mode.
@Command([OpenDocument])
2. This formula also opens the selected document in Read mode.
@Command([OpenDocument];"0")
3. This formula opens the selected document in Edit mode and moves the cursor to the Subject field.
@Command([OpenDocument];"1");
@Command([EditGotoField];"Subject")
4. This formula opens a document by UNID.
@Command([OpenDocument];"";"F56ACC1F6F27155D8525686500603D43")
5. This formula opens the document, Savage Mountain, in the By Title view of a Web application.
@Command([OpenView];"By Title";"Savage Mountain");
@Command([OpenDocument])
6. This formula opens the document, Savage Mountain, in Edit mode when it is accessed by a browser.
@Command([OpenView];"By Title";"Savage Mountain");
@Command([OpenDocument]; "1")
Syntax
@Command( [OpenFrameset] ; frameset )
Parameters
frameset
Usage
@Command([OpenFrameset]) is used in action formulas.You can use this command in Web applications.
Language cross-reference
OpenFrameSet method in LotusScript NotesUIWorkspace class
Examples: @Command([OpenFrameset])
This code, when added to an action button on a form, saves and closes the current form and opens the
usersView frameset.
@Command([FileSave]);
@Command([CloseWindow]);
@Command([OpenFrameset];"usersView")
OpenHelpDocument @Command
Allows you to create your own context-sensitive help documents. To use this command, you must first
create a view that has a sorted first column containing key values that uniquely identify each help
document. @Command([OpenHelpDocument]) searches this sorted view for the specified key value and,
if found, displays the associated help document in a separate Help window.
Tip: If you use this @command as the formula for the onHelp event for a form, for example, when a user
presses <F1> in the context of this form, the custom help document associated with it displays instead of
the standard Notes Help database that is usually triggered when a user presses <F1>.
Syntax
@Command( [OpenHelpDocument]; server :database;viewname; key )
or
database
Text. Required. The path and file name (in the appropriate format for the operating system) of the
database you want to open.
viewName
Text. The name of the view you want to open in the database.
key
Text. Indicates which document you want Notes to scroll to when it opens viewName. The key is a value
that appears in the first sorted column of viewName. It can either be a formula or a hard-coded value such
as the title of a document.
[HelpDatabase]
Keyword. If you supply one of the following keywords instead of server:database values, this @command
opens the corresponding Lotus Notes Help files:
Usage
In the Help database, the column that contains the key must be sorted.
The Help database must be on either a server or in the local data directory. If you do not specify the
server name, it defaults to your local data directory.
If you do not specify the database name, it searches within the Help database. For example, in the Notes
6 Client, the search occurs in Lotus Domino 6 Help (HELP6_CLIENT.nsf).
For Web access, this command is useful to create a button to get Help documents.
Tip: You can also create pages for Help and open them with @Command([OpenPage]).
Examples: @Command([OpenHelpDocument])
1. This formula, when added to a view action labeled Help, opens a specific help document when a user
triggers it. It displays the document that contains the value customerView in its about field in a
Help window. The myHelpDocs view is a hidden view containing all the custom help documents for
the database. Its first column is a sorted column containing the value of the about field. Since this
formula specifies no server, database, or keywords, OpenHelpDocument searches the current database
for the specified Help document.
@Command([OpenHelpDocument];"";"myHelpDocs";"customerView")
2. This formula, when added to a hotspot button labeled Help on a form, opens a Help window that
displays a custom Help document. It displays the document that contains the value orderForm in its
OpenNavigator @Command
Opens a navigator defined for the selected database.
Syntax
@Command( [OpenNavigator] ; navigator ; solo )
Parameters
navigator
Text. The name of a navigator defined for the selected database. OpenNavigator opens this navigator in
an existing navigation pane or window.
solo
Number (1). Optional. If you include this value, Notes opens the specified navigator in its own
window.
Usage
OpenNavigator opens this specified navigator in an existing navigation pane or window.
You can use this command in Web applications but you must omit the solo argument.
Language cross-reference
OpenNavigator method in LotusScript NotesUIDatabase class
OpenPage @Command
Opens a page defined for the current database. A page is a design element that structures and displays
information, including text, graphics, applets, and links. Unlike a form, a page cannot contain fields,
subforms, layout regions, and some embedded controls.
Syntax
@Command( [OpenPage] ; page )
Parameters
page
Language cross-reference
OpenPage method in LotusScript NotesUIWorkspace class
OpenView @Command
Opens the specified view in the current database.
Syntax
@Command( [OpenView] ; viewName ; key ; newinstance )
Parameters
viewName
Text. Optional. The name of the view you want to open. If you omit the view name, the database opens
to its default view; or, if the user has opened the database before, to the last view used by that person. If
the database is already open to the specified view, Notes/Domino makes that the topmost window.
key
Text. Optional. Indicates which document you want Notes/Domino to scroll to when it opens viewName.
The key is a value that appears in the first sorted column of viewName. If you omit the key, no document
is selected.
newinstance
Number. Optional. Specify 1 if you want the view to open in a new window, even if theres already a
window open for the database. If you omit this parameter, the new window is opened only when its
actually needed.
Note: The view must be sorted in order for the key to work; otherwise, no document is selected when the
view opens. The key column must be the first sorted column when multiple sorted columns are present.
Usage
You can use this command in Web applications.
If you specify the newinstance parameter for @Command([OpenView]), the @SetTargetFrame function is
ignored.
If you do not specify a viewName then the last view is the one that will open in the specified targetframe
of @SetTargetFrame.
Language cross-reference
OpenView method in LotusScript NotesUIDatabase class
PasteBitmapAsBackground @Command
Pastes a bitmap into the background of a navigator. All other objects in the navigator are displayed on
top of the background bitmap.
Syntax
@Command( [PasteBitmapAsBackground] )
Usage
A navigator must be open in Design mode, and the bitmap you want to paste must be on the Clipboard.
PasteBitmapAsObject @Command
Pastes a bitmap into a navigator. The bitmap becomes a hotspot which can be edited like any other
hotspot.
Syntax
@Command( [PasteBitmapAsObject] )
Usage
A navigator must be open in Design mode, and the bitmap you want to paste must be on the Clipboard.
PictureProperties @Command
Displays the Properties box for a bitmap in a rich text field.
Syntax
@Command( [PictureProperties] )
Usage
A bitmap must be selected.
PublishDatabase @Command
Displays the Publish Database dialog box, where the user selects a library in which to publish the
selected database.
Usage
A database must be open or selected on the workspace. Only one database can be selected. There must be
at least one library on the users workspace.
RefreshFrame @Command
Refreshes the specified frame in a frameset.
Syntax
@Command( [RefreshFrame]; targetFrame )
Parameters
targetFrame
If you omit the frame name, no frames are refreshed. You can omit the targetFrame parameter if you
specify a target frame using the @SetTargetFrame function before executing this command.
Usage
If the command is executed in nested framesets that have two frames which share the same name, Notes
refreshes the frame in the outermost frameset only.
In Web applications, @Command([RefreshFrame]) ignores the targetFrame parameter and refreshes only
the frame from which the command is executed.
Syntax
@Command( [RefreshHideFormulas] )
Usage
A document or view must be open.
Language cross-reference
RefreshHideFormulas method of LotusScript NotesUIDocument class
RefreshParentNote @Command
This formula sends the values entered in the dialog box to the parent document. A designer can update a
parent note and close the dialog box without having to use the OK button on the dialog box.
Syntax
@Command( [RefreshParentNote] )
Usage
Used only in dialog boxes.
Language cross-reference
RefreshParentNote method of LotusScript NotesUIWorkspace class
Examples: @Command([RefreshParentNote])
1. This code, when added to the Refresh hotspot button on the userInput form, updates fields in the
parent document that share names with fields in the userInput form if the userInput form is called
from the parent document using the @DialogBox function.
@Command([RefreshParentNote])
The @DialogBox function could be used in a hotspot button on the parent document with the
following code:
@DialogBox("userInput";[NOOKCANCEL]:[NOCANCEL];"User input")
RefreshWindow @Command
Reloads or refreshes the contents of the current window.
Syntax
@Command( [RefreshWindow] )
If the window is a frameset, then the entire frameset and its contents are reloaded. Also, a Web page in a
frame in the current window will be reloaded from the Web. All other windows are refreshed.
Language cross-reference
ReloadWindow method of LotusScript NotesUIWorkspace class
ReloadWindow @Command
Reloads or refreshes the contents of the current window.
Syntax
@Command( [ReloadWindow] )
Usage
This command executes after all @functions. Use the @Command([RefreshWindow]) to execute
immediately. See the Order of evaluation for formula statements topic for more details.
If the window is a frameset, then the entire frameset and its contents are reloaded. Also, a Web page in a
frame in the current window will be reloaded from the Web. All other windows are refreshed.
Language cross-reference
ReloadWindow method of LotusScript NotesUIWorkspace class
RemoteDebugLotusScript @Command
From the Lotus Notes Remote Debugger client, opens the Select Debug Target dialog box.
Syntax
@Command([RemoteDebugLotusScript])
Usage
This function works only from within the Remote Debugger client. To access the Lotus Notes Debugger
client from Designer, select File - Tools - Remote Debugging from the Designer menu.
This function is used in the Attach to a debug target icon on the Debugger Welcome Page to mimic the
File - Select Debug Target menu command.
RemoveFromFolder @Command
Removes the selected document from the current folder.
Syntax
@Command( [RemoveFromFolder] )
This @command works on the Web if Use applet in the browser is in effect for the implementing view
or folder.
Language cross-reference
RemoveFromFolder method of LotusScript NotesDocument class
RenameDatabase @Command
For a particular database on the users workspace, RenameDatabase locates a replica of that database
(based on its replica ID) on the specified server, and replaces the database icon with that of the replica.
The only change the user sees is that the server name has changed on the database icon.
Syntax
@Command( [RenameDatabase] ; server : database ; newServer )
Parameters
server
database
Text. The path and file name of the database. Specify the databases name and location using the
appropriate format for the operating system.
newServer
Text. The name of the server where a replica of the database is.
Usage
You can only use this for replicasof a database, not copies. You cannot use this command to change the
name of a server.
If the workspace has stacked replica icons for the database on both server and newServer, RenameDatabase
brings the icon for newServer to the front.
Language cross-reference
OpenByReplicaID method of LotusScript NotesDatabase class
Replicator @Command
Displays the Replicator on the Notes workspace page.
Syntax
@Command( [Replicator] )
Usage
This command does not work on the Web.
ReplicatorReplicateHigh @Command
Initiates replication of databases that have been assigned a priority of High.
Syntax
@Command( [ReplicatorReplicateHigh] )
Usage
ReplicatorReplicateHigh is available only when Notes is open to the Replicator workspace page.
ReplicatorReplicateNext @Command
Stops replication of the currently replicating database and initiates replication of the next database
selected for replication.
Syntax
@Command( [ReplicatorReplicateNext] )
Usage
ReplicatorReplicateNext may result in partial replication of the currently replicating database.
ReplicatorReplicateNext is available only when Notes/Domino is open to the Replicator workspace page.
Syntax
@Command( [ReplicatorReplicateSelected] )
Usage
ReplicatorReplicateSelected is available only when Notes/Domino is open to the Replicator workspace
page.
ReplicatorReplicateWithServer @Command
Displays the Replicate With Which Server dialog box and initiates replication with the server you select.
Syntax
@Command( [ReplicatorReplicateWithServer] )
Usage
ReplicatorReplicateWithServer is available only when Notes/Domino is open to the Replicator workspace
page.
Language cross-reference
Replicate method of LotusScript NotesDatabase class
ReplicatorSendMail @Command
Sends local pending mail to the server.
Syntax
@Command( [ReplicatorSendMail] )
Usage
ReplicatorSendMail is available only when Notes/Domino is open to the Replicator workspace page.
ReplicatorSendReceiveMail @Command
Initiates replication between the mail server and your local mail database.
Usage
ReplicatorSendReceiveMail is available only when Notes/Domino is open to the Replicator workspace
page.
ReplicatorStart @Command
Initiates or resumes replication of the selected databases.
Syntax
@Command( [ReplicatorStart] )
Usage
ReplicatorStart is available only when Notes/Domino is open to the Replicator workspace page.
Language cross-reference
Replicate method of LotusScript NotesDatabase class
ReplicatorStop @Command
Stops the current replication process.
Syntax
@Command( [ReplicatorStop] )
Usage
ReplicatorStop may result in partial replication of the currently replicating database.
ReplicatorStop is available only when Notes/Domino is open to the Replicator workspace page.
RunAgent @Command
Executes a specified agent.
Parameters
agent
If you omit the agent name, Notes displays a list of Agents in the database, where the user can select
which agent to run.
Usage
This command executes immediately. Use the ToolsRunMacro @command to execute after all @functions.
See the Order of evaluation for formula statements topic for more details.
Language cross-reference
Run method of LotusScript NotesAgent class
RunScheduledAgents @Command
Runs all of the databases scheduled agents, regardless of when they are scheduled to run. The agents
will then run as usual at their regularly scheduled times.
Syntax
@Command( [RunScheduledAgents] )
Usage
This command executes immediately. Use the ToolsRunBackgroundMacros @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
SectionCollapse @Command
Collapses the current section in a document, form, or subform.
Syntax
@Command( [SectionCollapse] )
SectionCollapseAll @Command
Collapses all the sections in a document, page, form, or subform.
Syntax
@Command( [SectionCollapseAll] )
Usage
v A document must be open in Read or Edit mode.
v A form or subform must be open in Design mode.
If sections exist in a table only, this command triggers the message, Cannot execute the specified
command. To prevent this behavior, add a section outside the table, to the page or form background.
Language cross-reference
CollapseAllSections method of LotusScript NotesUIDocument class
SectionDefineEditors @Command
Displays the Edit Section dialog box for the current section on a form.
Syntax
@Command( [SectionDefineEditors] )
Usage
The current section must be a controlled access section and the form must be open in Edit mode.
SectionExpand @Command
Expands the current section in a document, form, or subform.
Syntax
@Command( [SectionExpand] )
Usage
v A document must be open in Read or Edit mode and a section must be selected.
v A form or subform must be open in Design mode and a section must be selected.
Syntax
@Command( [SectionExpandAll] )
Usage
v A document must be open in Read or Edit mode.
v A form or subform must be open in Design mode.
If sections exist in a table only, this command triggers the message, Cannot execute the specified
command. To prevent this behavior, add a section outside the table, to the page or form background.
Language cross-reference
ExpandAllSections method of LotusScript NotesUIDocument class
SectionProperties @Command
On a form or subform, displays the Properties box for the selected section.
Syntax
@Command( [SectionProperties] )
Usage
v A form or subform must be open in Design mode and a section must be selected. SectionProperties
does not work for sections on documents based on that form or subform.
v A document must be open in Edit mode and a section in a rich text field must be selected.
SectionRemoveHeader @Command
Removes the contents of a section from the section. The contents are then displayed as they existed before
the section was created.
Syntax
@Command( [SectionRemoveHeader] )
Usage
v A document must be open in Edit mode with a section selected
or
v A form or subform must be open in Design mode with a section selected
Syntax
@Command( [SendInstantMessage] ; names )
Parameters
names
Text list. Optional. The name or names to start chatting with. If this parameter is omitted, the user is
prompted.
SetCurrentLocation @Command
Displays the Choose Location dialog box, where you can choose your current workstation location, such
as Office, Island, or Travel.
Syntax
@Command( [SetCurrentLocation] )
Usage
This command works everywhere in Notes/Domino. It does not work in Web applications. Its most
convenient to use a toolbar button to invoke this command.
Language cross-reference
SetCurrentLocation method of LotusScript NotesUIWorkspace class
ShowHideIMContactList @Command
Toggles the display of the Instant Messaging Contact List.
Syntax
@Command( [ShowHideIMContactList] )
ShowHideLinkPreview @Command
Toggles the display of the link preview pane.
Syntax
@Command( [ShowHideLinkPreview] ; showOrHide )
Parameters
showOrHide
Number. Optional. Specify 1 if you want to show the link preview pane, 0 if you want to hide it. If
you omit this parameter, the @command toggles the current state of the link preview pane.
Language cross-reference
PreviewDocLink property of LotusScript NotesUIDocument class
ShowHideParentPreview @Command
Toggles the display of the parent document preview pane.
Syntax
@Command( [ShowHideParentPreview] ; showOrHide )
Parameters
showOrHide
Number. Optional. Specify 1 if you want to show the parent preview pane, 0 if you want to hide it. If
you omit this parameter, the @command toggles the current state of the parent preview pane.
Usage
A document must be open in Read or Edit mode.
Language cross-reference
PreviewParentDoc property of LotusScript NotesUIDocument class
ShowHidePreviewPane @Command
Toggles the display of the document preview pane.
Syntax
@Command( [ShowHidePreviewPane] ; showOrHide )
Parameters
showOrHide
Number. Optional. Specify 1 if you want to show the document preview pane, 0 if you want to hide
it. If you omit this parameter, the @command toggles the current state of the document preview pane.
Usage
A document must be selected in a view or folder.
Language cross-reference
InPreviewPane property of LotusScript NotesUIDocument class
Syntax
@Command( [ShowProperties] )
Usage
This command does not work on the Web.
SmartIconsFloating @Command
Makes the SmartIcons palette float so that users can move it around on the screen.
Syntax
@Command( [SmartIconsFloating] )
Usage
This command does not work on the Web.
SmartIconsNextSet @Command
Switches to display the next set of SmartIcons in the Icon bar.
Syntax
@Command( [SmartIconsNextSet] )
Usage
This command does not work on the Web.
StyleCycleKey @Command
Cycles through the list of styles that have been defined for the current document, form, or page. This is
the same as pressing F11. Each time you invoke StyleCycleKey, a different style goes into effect.
Syntax
@Command( [StyleCycleKey] )
Usage
v A document must be open in Edit mode
or
v A form, subform, or page must be open in Design mode
In both cases, there must be at least two styles assigned to the style cycle list.
SwitchForm @Command
Changes the form used to display the current document.
Syntax
@Command( [SwitchForm] ; formName )
Parameters
formName
Text. Optional. The name of the form you want to switch to.
With no parameter, ViewSwitchForm displays a dialog box with a list of forms available in the current
database.
Usage
This command executes immediately. Use the ViewSwitchForm @command to execute after all
@functions. See the Order of evaluation for formula statements topic for more details.
SwitchView @Command
Switches to the specified view or folder within the current database or, if a view or folder is not specified,
displays the View menu so the user can select a view.
Syntax
@Command( [SwitchView] )
or
Parameters
viewName
Text. Optional. The name of the view or folder you want to switch to.
Usage
This command executes immediately. Use the ViewChange @command to execute after all @functions.
See the Order of evaluation for formula statements topic for more details.
This command doesnt work from within a document or form, so you cannot use it to view a document
through another form. Use @Command([SwitchForm]) instead.
You can use this command in Web applications, but you must use the viewName parameter.
TextAlignCenter @Command
Centers the current text.
Syntax
@Command( [TextAlignCenter] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode.
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
TextAlignFull @Command
Aligns the text at both the right and left edges of the field so that the text forms a block.
Syntax
@Command( [TextAlignFull] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode.
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
TextAlignLeft @Command
Aligns text along the left margin.
Syntax
@Command( [TextAlignLeft] )
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
TextAlignNone @Command
Reverses the previously specified alignment settings.
Syntax
@Command( [TextAlignNone] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode.
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
TextAlignRight @Command
Aligns text along the right margin.
Syntax
@Command( [TextAlignRight] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode.
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
Syntax
@Command( [TextBold] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
or
v A textbox must be selected in a navigator, with all the text in the textbox becoming bold
or
v A textbox must be selected in a layout region on a form, with all of the text in the textbox becoming
bold
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
Bold property of LotusScript NotesRichTextStyle class
TextBullet @Command
Applies the bullet attribute to selected and subsequently entered text.
Syntax
@Command( [TextBullet] ; onOff )
Parameters
onOff
Number. Optional. Specify 1 to turn the bullet attribute on; specify 0 to turn it off. If you omit this
parameter, the command toggles from the current state.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
TextCycleSpacing @Command
Resets the interline spacing below the selected text to single, one and a half, or double.
Usage
Text must be selected in a rich text field in a document open in Edit mode or on a form or Page open in
Design mode. TextCycleSpacing acts as a three-way toggle that sets the spacing below each line of
selected text from single to one and a half, or from one and a half to double, or from double to single. If
interline spacing in the selected text is not uniform, TextCycleSpacing sets it to single.
Some text must be selected in a rich text field in a document open in Edit mode or a form open in
Design mode.
TextEnlargeFont @Command
Increases selected and subsequently entered text to the next larger point size.
Syntax
@Command( [TextEnlargeFont] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
FontSize property of LotusScript NotesRichTextStyle class
TextFont @Command
Displays the Properties box for the current text, where the user can select the typeface, size, color, and
style attributes.
Syntax
@Command( [TextFont] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
TextItalic @Command
Italicizes the selected and subsequently entered text. This command is a toggle; selecting it a second time
removes the italics.
Syntax
@Command( [TextItalic] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
or
v A textbox must be selected in a navigator, with all the text in the textbox becoming italics
or
v A textbox must be selected in a layout region on a form, with all the text in the textbox becoming
italics
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
Italic property of LotusScript NotesRichTextStyle class
TextNormal @Command
Removes all style attributes from selected and subsequently entered text.
Syntax
@Command( [TextNormal] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
or
v A textbox must be selected in a navigator, with all the text in the textbox going back to plain text
or
v A textbox must be selected in a layout region on a form, with all the text in the textbox going back to
plain text
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
TextNumbers @Command
Applies the numbers attribute to selected and subsequently entered text.
Syntax
@Command( [TextNumbers] ; onOff )
Parameters
onOff
Number. Optional. Specify 1 to turn the numbers attribute on; specify 0 to turn it off. If you omit this
parameter, the command toggles from the current state.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
TextOutdent @Command
Outdents selected and subsequently entered text by narrowing its left margin.
Syntax
@Command( [TextOutdent] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
LeftMargin property of LotusScript NotesRichTextParagraphStyle class
TextParagraph @Command
Displays the Paragraph Alignment panel of the Text Properties box.
Syntax
@Command( [TextParagraph] )
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
TextParagraphStyles @Command
Displays the Paragraph Styles panel of the Text Properties box.
Syntax
@Command( [TextParagraphStyles] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v You can use a toolbar button to invoke this command if the text is already selected
Language cross-reference
Alignment property of LotusScript NotesRichTextParagraphStyle class
TextPermanentPen @Command
Toggles the permanent pen.
Syntax
@Command( [TextPermanentPen] ; onOff )
Parameters
onOff
Number. Specify 1 to turn permanent pen on; specify 0 to turn it off. Omit this parameter to toggle
the permanent pen.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
Chapter 7. Formula Language @Commands A-Z 605
v You can use a toolbar button to invoke this command if the text is already selected
Language cross-reference
IsDefault property of LotusScript NotesRichTextStyle class
TextReduceFont @Command
Decreases the selected text to the next smaller point size.
Syntax
@Command( [TextReduceFont] )
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
v Its most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
FontSize property of LotusScript NotesRichTextStyle class
TextSetFontColor @Command
Displays selected or subsequently entered text using the specified color.
Syntax
@Command( [TextSetFontColor] ; [ color ] )
Parameters
[ color ]
The name of the color you want your text to be. The available colors are:
v Black
v Gray
v Red
v DarkRed
v Green
v DarkGreen
v Blue
v DarkBlue
v Magenta
v DarkMagenta
v Yellow
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
It is most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
NotesColor property of LotusScript NotesRichTextStyle class
Examples: TextSetFontColor
1. This formula sets the text color to dark cyan.
@Command([TextSetFontColor]; [DarkCyan])
TextSetFontFace @Command
Displays selected or subsequently entered text using the specified typeface.
Syntax
@Command( [TextSetFontFace] ; typeface )
Parameters
typeface
Text. The name of the font you want. The list of available typefaces depends upon the platform you are
using, and whether you are using any add-in typeface software. Click the left-most tab on the status bar
for a list of available typefaces.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
It is most convenient to use a toolbar button to invoke this command if the text is already selected.
Language cross-reference
NotesFont property of LotusScript NotesRichTextStyle class
TextSetFontSize @Command
Displays text using the specified point size.
Syntax
@Command( [TextSetFontSize]; size )
Parameters
size
Text. The font size you want. If you specify a nonexistent size, Notes uses the closest match.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
It is most convenient to use a toolbar button to invoke this command if the text is already selected
Language cross-reference
FontSize property of LotusScript NotesRichTextStyle class
Examples: TextSetFontSize
This formula sets the font size to 10 points.
@Command([TextSetFontSize]; "10")
TextSpacingDouble @Command
Sets Interline spacing below the selected text to double.
Syntax
@Command( [TextSpacingDouble] )
Language cross-reference
InterLineSpacing property of LotusScript NotesRichTextParagraphStyle class
TextSpacingOneAndAHalf @Command
Sets interline spacing below the selected text to one and a half.
Syntax
@Command( [TextSpacingOneAndAHalf] )
Usage
Text must be selected in a rich text field in a document open in Edit mode or on a form or page open in
Design mode.
Language cross-reference
InterLineSpacing property of LotusScript NotesRichTextParagraphStyle class
TextSpacingSingle @Command
Sets interline spacing below the selected text to single.
Syntax
@Command( [TextSpacingSingle] )
Usage
Text must be selected in a rich text field in a document open in Edit mode or on a form or page open in
Design mode.
Language cross-reference
InterLineSpacing property of LotusScript NotesRichTextParagraphStyle class
TextUnderline @Command
Underlines selected and subsequently entered text. This command is a toggle; selecting it a second time
removes the underlining.
Usage
v A document must be open in Edit mode with the insertion point in a rich text field
or
v A form, subform, or page must be open in Design mode
or
v A textbox must be selected in a navigator, with all of the text in the textbox being underlined
or
v A textbox must be selected in a layout region on a form, with all of the text in the textbox being
underlined
Its most convenient to use a toolbar button to invoke this command if the text is already selected.
Language cross-reference
Underline property of LotusScript NotesRichTextStyle class
ToolsCall @Command
Displays the Call Server dialog box, where the user can select a server to dial in to.
Syntax
@Command( [ToolsCall] )
Usage
This command does not work on the Web.
Language cross-reference
ServerName property of LotusScript NotesAgent class
ToolsCategorize @Command
Categorizes the current document.
Syntax
@Command( [ToolsCategorize] )
or
Parameters
category
Usage
v If you include category, the selected documents are moved to that category. If you dont include
category, Notes/Domino displays the Categorize dialog box so the user can select a category.
In a view, all selected documents are categorized.
In a document in Read or Edit mode, only that document is categorized.
v The current view must be a categorized view where the first categorized column sorts on a field
named categories
Language cross-reference
Categorize method in LotusScript NotesUIDocument class
Examples: ToolsCategorize
1. This formula displays the Categorize dialog box.
@Command([ToolsCategorize])
2. This formula moves the selected documents to the Weekly Status Report category.
@Command([ToolsCategorize]; "Weekly Status Reports")
ToolsHangUp @Command
Displays the Hang Up dialog box.
Syntax
@Command( [ToolsHangUp] )
Usage
This command does not work on the Web.
ToolsMarkAllRead @Command
Marks all of the documents in a database as read.
Syntax
@Command( [ToolsMarkAllRead] )
Usage
v A database must be open at the view or folder level
or
v A document must be open in Read or Edit mode
Note: In some databases, there is no difference in the display of read and unread documents in views
and folders.
Syntax
@Command( [ToolsMarkAllUnread] )
Usage
v A database must be open at the view level
or
v A document must be open in Read or Edit mode
Note: In some databases, there is no difference in the display of read and unread documents in views
and folders.
ToolsMarkSelectedRead @Command
In a view or folder, marks all of the selected documents as read.
Syntax
@Command( [ToolsMarkSelectedRead] )
Usage
v A database must be open at the view level
or
v A document must be open in Read or Edit mode
Note: In some databases, there is no difference in the display of read and unread documents in views
and folders.
ToolsMarkSelectedUnread @Command
In a view or folder, marks all of the selected documents as unread.
Syntax
@Command( [ToolsMarkSelectedUnread] )
Usage
v A database must be open at the view level
or
v A document must be open in Read or Edit mode
Note: In some databases, there is no difference in the display of read and unread documents in views
and folders.
Syntax
@Command( [ToolsRefreshAllDocs] )
Usage
A database must be open at the view or folder level.
Language cross-reference
Refresh method of LotusScript NotesView class
ToolsRefreshSelectedDocs @Command
Refreshes the fields of all the selected documents in a view or folder.
Syntax
@Command( [ToolsRefreshSelectedDocs] )
Usage
A database must be open at the view or folder level and at least one document must be selected.
ToolsReplicate @Command
Displays the Replicate dialog box, where the user can choose to replicate the current database using the
options defined in Replicator or using special one-time options.
Syntax
@Command( [ToolsReplicate] ; repMethod )
Parameters
repMethod
Number. Optional. A value of 1 specifies replication using the options that the user can set. A value of
0 specifies replication using the options defined in Replicator. If this parameter is omitted,
Notes/Domino prompts the user to choose between these two replication methods.
Usage
A database must be open or selected on the workspace.
ToolsRunBackgroundMacros @Command
Runs all of the databases scheduled agents, regardless of when they are scheduled to run. The agents
will then run as usual at their regularly scheduled times.
Syntax
@Command( [ToolsRunBackgroundMacros] )
Usage
This command executes after all @functions. Use @Command([RunScheduledAgents]) to execute
immediately. See the Order of evaluation for formula statements topic for more details.
ToolsRunMacro @Command
Executes a specified agent.
Syntax
@Command( [ToolsRunMacro] ; agent )
Parameters
agent
If you omit the agent name, Notes displays a list of Agents in the database, where the user can select
which agent to run.
Usage
This command executes after all @functions. Use @Command([RunAgent]) to execute immediately. See
the Order of evaluation for formula statements topic for more details.
Language cross-reference
Run method of LotusScript NotesAgent class
ToolsScanUnreadChoose @Command
Displays the Scan Unread Preferred Setup dialog box, where the user can select the preferred databases to
be scanned for unread documents.
Syntax
@Command( [ToolsScanUnreadChoose] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
ToolsScanUnreadPreferred @Command
Displays the Scan Unread dialog box, where the user can see unread counts for each of the user preferred
databases.
Syntax
@Command( [ToolsScanUnreadPreferred] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
ToolsScanUnreadSelected @Command
Opens the selected database to the first unread document. The user can then navigate to subsequent
unread documents.
Syntax
@Command( [ToolsScanUnreadSelected] )
Usage
v If one database is selected on the workspace, Notes/Domino opens the first unread document in the
database
v If multiple databases are selected, Notes/Domino displays the Scan Unread dialog box, where the user
can see the unread count for each database
v If no database is selected on the workspace, Notes/Domino displays the Scan Unread dialog box,
which allows you to select a database with unread documents to open
ToolsSetupLocation @Command
Opens the current location document in your Personal Address Book in Edit mode, allowing you to
change your home server, mail database location, and time zone.
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
ToolsSetupMail @Command
Displays the Mail section of the User Preferences dialog box, where the user can indicate how often
Notes should check for new mail, whether to sign and encrypt outgoing mail, and so on.
Syntax
@Command( [ToolsSetupMail] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
ToolsSetupPorts @Command
Displays the Ports section of the User Preferences dialog box, where the user can enable and disable
network ports.
Syntax
@Command( [ToolsSetupPorts] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
ToolsSetupUserSetup @Command
Displays the Basics section of the User Preferences dialog box, where the user defines Notes startup
options.
Syntax
@Command( [ToolsSetupUserSetup] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
ToolsSmartIcons @Command
Displays the Toolbar Preferences dialog box where you can create new toolbars and customize the content
and display of existing toolbars.
Note: In pre-Release 6 clients, displays the SmartIcons dialog box where the user can create SmartIcons
and define SmartIcon sets.
Usage
You can also access this dialog box manually, by clicking File - Preferences - Toolbar Preferences.
This can be used anywhere within Notes/Domino except from within a dialog box. This command does
not work on the Web.
ToolsSpellCheck @Command
Starts the Notes spell checker.
Syntax
@Command( [ToolsSpellCheck] )
Usage
A document must be open in Edit mode.
Language cross-reference
SpellCheck method in LotusScript NotesUIDocument class
ToolsUserLogoff @Command
Logs the user off of all Domino servers. Reconnecting to a Domino server requires the user Notes ID and,
if one is set, password.
Syntax
@Command( [ToolsUserLogoff] )
Usage
This can be used anywhere in Notes/Domino except from within a dialog box. This command does not
work on the Web.
UserIDCertificates @Command
Displays the Certificates section of the User ID dialog box. If the user ID is passwordprotected, the user
must enter the password before displaying the dialog box.
Syntax
@Command( [UserIDCertificates] )
Usage
This command can be used almost anywhere in Notes/Domino except from within a dialog box. This
command does not work on the Web.
UserIDClearPassword @Command
Displays the Enter Password dialog box where the password associated with the user ID can be removed.
Usage
This can be used almost anywhere in Notes/Domino except from within a dialog box. This command
does not work on the Web.
UserIDCreateSafeCopy @Command
Displays the Enter Safe Copy ID File Name dialog box, where the user defines a file name for storing a
safe copy of the Notes/Domino user ID. The safe copy contains only the user name and public key. The
private key and all certificates are omitted from the safe copy.
Syntax
@Command( [UserIDCreateSafeCopy] )
Usage
This command can be used anywhere in Notes/Domino except from within a dialog box. This command
does not work on the Web.
UserIDEncryptionKeys @Command
Displays the Encryption section of the User ID dialog box. If the user ID is passwordprotected, the user
must enter the password before displaying the dialog box.
Syntax
@Command( [UserIDEncryptionKeys] )
Usage
This command can be used anywhere in Notes/Domino except from within a dialog box. This command
does not work on the Web.
UserIDInfo @Command
Displays the Basics section of the User ID Information dialog box.
Syntax
@Command( [UserIDInfo] )
Usage
This command can be used anywhere in Notes/Domino except from within a dialog box. This command
does not work on the Web.
Language cross-reference
GetUserInfo method of LotusScript NotesRegistration class
Syntax
@Command( [UserIDMergeCopy] )
Usage
This command can be used anywhere in Notes/Domino except from within a dialog box. This command
does not work on the Web.
UserIDSetPassword @Command
Displays the Set Password dialog box where the user can enter a new password for the Notes/Domino
ID. If a password already exists, the user must enter the existing password before specifying a new one.
Syntax
@Command( [UserIDSetPassword] )
Usage
This command can be used anywhere in Notes/Domino except from within a dialog box. This command
does not work on the Web.
Language cross-reference
RegisterNewCertifier method of LotusScript NotesRegistration class
UserIDSwitch @Command
Displays the Choose User ID to Switch To dialog box. If the selected ID is passwordprotected,
Notes/Domino next displays the Enter Password dialog box, where the user must enter the correct
password.
Syntax
@Command( [UserIDSwitch] )
Usage
This command can be used in hotspot actions or buttons and view or form action formulas.
Language cross-reference
SwitchToID method of LotusScript NotesRegistration class
Syntax
@Command( [V3EditNextField] )
Usage
v Use V3EditNextField to enable your application to run under Release 3 of Lotus Notes
v When used in a SmartIcons formula(pre-Release 6), V3EditNextField moves the insertion point to the
next editable field in the document, working left to right and top to bottom
v When used in a button thats built into the form, the first occurrence of V3EditNextField always moves
the insertion point to the first field in the document. You must add an additional
@Command([V3EditNextField]) to move to each subsequent field (or you could use a related command
such as EditUp or EditDown)
v A document must be open in Edit mode
Language cross-reference
GoToNextField method of LotusScript NotesUIDocument class
V3EditPrevField @Command
In a document in Edit mode, moves the insertion point to the first editable field.
Syntax
@Command( [V3EditPrevField] )
v Use V3EditPrevField to enable your application to run under Release 3 of Notes
v When used in a SmartIcons formula(pre-Release 6), V3EditPrevField moves the insertion point to the
first editable field in the document, working right to left and bottom to top
v When used in a button thats built into the form, the first occurrence of V3EditPrevField always moves
the insertion point to the first field in the document. You must add an additional
@Command([V3EditPrevField]) to move to the last field on the form, and again for each additional
field (or you could use a related command such as EditUp or EditDown)
v A document must be open in Edit mode
Language cross-reference
GoToPrevField method of LotusScript NotesUIDocument class
ViewArrangeIcons @Command
Aligns database icons on the current workspace page from left to right and top to bottom.
Syntax
@Command( [ViewArrangeIcons] )
ViewBelowFolders @Command
Places the view pane at the bottom of the screen and the folder pane at the top.
Syntax
@Command( [ViewBelowFolders] )
Usage
A database must be open at the view or folder level.
ViewBesideFolders @Command
Places the view pane at the right of the screen and the folder pane at the left.
Syntax
@Command( [ViewBesideFolders] )
Usage
A database must be open at the view or folder level.
ViewCertify @Command
Displays the Choose Certifier ID dialog box, in which you specify the certification to be renewed for the
selected user or users.
Syntax
@Command( [ViewCertify] )
Usage
ViewCertify is available once you have opened a server Domino Directory to the People view and
selected one or more Person documents. View Certify enables you to initiate recertification of the selected
user or users by the Administration Process.
Language cross-reference
Recertify method of LotusScript NotesRegistration class
Syntax
@Command( [ViewChange] )
or
Parameters
viewName
Text. Optional. The name of the view or folder you want to switch to.
Usage
This command executes after all @functions. Use @Command([SwitchView]) to execute immediately. See
the Order of evaluation for formula statements topic for more details.
This command doesnt work from within a document or form, so you cannot use it to view a document
through another form. Use SwitchForm instead.
You can use this command in Web applications, but you must use the viewName parameter.
Language cross-reference
OpenView method of LotusScript NotesUIDatabase class
Examples: ViewChange
This formula switches to the By Author view.
@Command([ViewChange]; "By Author")
ViewCollapse @Command
Collapses all levels of subcategories, documents, and responses within the current category, so only the
topmost category name shows. If the view or folder has a response hierarchy but is not categorized,
ViewCollapse collapses all levels of response documents under the current main document.
Syntax
@Command( [ViewCollapse] )
Usage
v A database must be open at a view or folder that uses categories and/or a response hierarchy
Syntax
@Command( [ViewCollapseAll] )
Usage
v A database must be open at the view or folder level
v You can use this command in Web applications
Examples: @Command([ViewCollapseAll])
This code, when added as the formula for an Action to a view, collapses all main and response
documents per category in views that have categories and collapses all response documents under main
documents in views that do not have categories.
@Command([ViewCollapseAll])
ViewExpand @Command
Expands one level of subcategories, documents, and responses within the current category. If the view or
folder has a response hierarchy but is not categorized, ViewExpand expands all levels of response
documents under the current main document.
Syntax
@Command( [ViewExpand] )
Usage
v A database must be open at a view or folder that uses categories and/or a response hierarchy
ViewExpandAll @Command
Expands all levels of categories, subcategories, documents, and responses within the view or folder.
Syntax
@Command( [ViewExpandAll] )
Usage
v A database must be open at a view or folder that uses categories, a response hierarchy, or both. If the
view or folder has a response hierarchy but is not categorized, ViewExpandAll expands all levels of
response documents under the main documents
v You can use this command in Web applications
ViewExpandWithChildren @Command
Expands all levels of subcategories, documents, and responses within the selected category.
Syntax
@Command( [ViewExpandWithChildren] )
Usage
This command does not work on the Web.
ViewHorizScrollBar @Command
Toggles display of the horizontal scroll bar in a view or folder.
Note: ViewHorizScrollbar is not supported in Release 6; with Release 6, the view automatically supplies
a scrollbar when necessary. In pre-release 6 versions, ViewHorizScrollbar is not supported under OS/2
and on the Macintosh.
Syntax
@Command( [ViewHorizScrollBar] )
Usage
A database must be open to a view or folder.
ViewMoveName @Command
Displays the Choose Certifier ID dialog box, which allows you to specify the organizational unit for
which you want to certify the selected user.
Syntax
@Command( [ViewMoveName] )
Usage
ViewMoveName is available once you have opened a server Domino Directory to the People view and
selected a Person document. ViewMoveName initiates the process of changing the users hierarchical
name through the Administration Process.
Language cross-reference
OrgUnit property of LotusScript NotesRegistration class
Syntax
@Command( [ViewNavigatorsFolders] )
Usage
A database must be open to a view or folder.
ViewNavigatorsNone @Command
Hides the navigator pane.
Syntax
@Command( [ViewNavigatorsNone] )
Usage
A database must be open to a view or folder.
ViewRefreshFields @Command
Recalculates the fields in the current document or updates the current view or folder.
Syntax
@Command( [ViewRefreshFields] )
Usage
v A document must be open in Edit mode
or
v A database must be open at the view or folder level
v When you execute this command on the Web in the current document, it recalculates all fields
formulas without closing the document. On the Web, you can only use this command for databases
where you have enabled JavaScript to generate the pages except as noted below
Language cross-reference
ViewRefresh method of LotusScript NotesUIWorkspace class
Syntax
@Command( [ViewRefreshUnread] )
Usage
A database must be open at the workspace.
ViewRenamePerson @Command
Displays the Certify Selected Entries dialog box, which enables you to upgrade the selected user name to
a hierarchical name, change the users common name, or change the users hierarchical name.
Syntax
@Command( [ViewRenamePerson] )
Usage
ViewRenamePerson is available once you have opened a server Domino Directory to the People view and
selected a Person document. ViewRenamePerson initiates the change you specify through the
Administration Process.
ViewShowFieldHelp @Command
Shows field Help, so that the Help description for the current field (if available) appears on the status bar
while the user composes or edits a document. (Field Help is a design option specified in the Field
Properties box.) This command is a toggle; selecting it a second time hides the field Help.
Syntax
@Command( [ViewShowFieldHelp] )
Usage
A document must be open in Edit mode.
Language cross-reference
FieldHelp property of LotusScript NotesUIDocument class
ViewShowObject @Command
Displays the object delimiter -- a dotted frame surrounding an OLE/LEL object within a field. This
command is a toggle; selecting it a second time hides the object delimiter so the OLE/LEL object looks
like regular, editable data.
Syntax
@Command( [ViewShowObject] )
ViewShowOnlyCategories @Command
Collapses the view or folder so that only category and subcategory names show up. This command is a
toggle; selecting it a second time expands all category levels.
Note: This view setting will remain active for all views until it is toggled off. If a view is not categorized,
and ViewShowOnlyCategories is toggled on, no documents will be displayed.
Syntax
@Command( [ViewShowOnlyCategories] )
Usage
A database must be open at the view level.
Language cross-reference
CreateViewNavMaxLevel method of LotusScript NotesView class
ViewShowOnlySearchResults @Command
Shows the results of a full-text search as selected documents in a view or folder. This command is a
toggle. Instead of listing only the documents that satisfy the search query (the default for a full-text
search), the view or folder lists all the documents it normally lists, with a check mark in front of those
documents that satisfy the search query.
Syntax
@Command( [ViewShowOnlySearchResults] )
Usage
A database must be open at the view or folder level, and a full-text search must have been run.
Language cross-reference
FTSearch method of LotusScript NotesView class
ViewShowOnlySelected @Command
Displays only the selected documents or categories in the view or folder (those documents with a check
mark). This command is a toggle; selecting it a second time displays all documents or categories.
Usage
A database must be open at the view or folder level.
ViewShowOnlyUnread @Command
Displays only the unread documents in the view or folder. This command is a toggle; selecting it again
displays all documents in the view or folder.
Syntax
@Command( [ViewShowOnlyUnread] )
Usage
A database must be open at the view or folder level.
ViewShowPageBreaks @Command
Displays a line representing each page break in the document. The page breaks indicate where Notes will
end each page when the document is printed on the currently selected printer. This command is a toggle;
selecting it a second time suppresses the display of automatic page breaks (manual page breaks will still
be displayed).
Syntax
@Command( [ViewShowPageBreaks] )
Usage
A document must be open in Edit mode.
ViewShowRuler @Command
Toggles the display of the ruler while a document is open in Edit mode.
Syntax
@Command( [ViewShowRuler] )
Usage
This command does not work on the Web.
ViewShowSearchBar @Command
Toggles the display of the full-text search bar at the top of the view. If the database does not have a
full-text index, the search bar displays but is not usable.
Parameters
onOff
Number. Specify 1 to show the search bar. Specify 0 to hide it. Omit this parameter to toggle the
display of the search bar.
Usage
You can use this command in Web applications. In the Notes client, this command can only be used with
views and folders.
ViewShowServerNames @Command
Toggles the display of server names on the database icons in the users workspace.
Syntax
@Command( [ViewShowServerNames] )
Usage
This command does not work on the Web.
ViewShowUnread @Command
Toggles the display of the unread document count on each database icon on the users workspace.
Syntax
@Command( [ViewShowUnread] )
Usage
This command does not work on the Web.
ViewSwitchForm @Command
Changes the form used to display the current document.
Syntax
@Command( [ViewSwitchForm] ; formName )
Parameters
formName
Text. Optional. The name of the form you want to switch to.
With no parameter, ViewSwitchForm displays a dialog box with a list of forms available in the current
database.
Usage
This command executes after all @functions. Use @Command([SwitchForm]) to execute immediately. See
the Order of evaluation for formula statements topic for more details.
WindowCascade @Command
Resizes all open Notes/Domino windows to less than 50% of their maximum window size and layers
them in a cascading stack. Because the layered stack is cascaded, the title bar of each window is visible
behind the stacks top-most window. To display a window that is lower in the stack, you can bring it to
the top by clicking its title bar.
Syntax
@Command( [WindowCascade] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
WindowMaximize @Command
Maximizes the active Notes/Domino window (the window whose title bar is highlighted).
Syntax
@Command( [WindowMaximize] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
WindowMaximizeAll @Command
Maximizes all open Notes/Domino windows. Notes/Domino windows include the Designer and
Administration client windows as well as any of the Notes Help windows.
Syntax
@Command( [WindowMaximizeAll] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
WindowMinimize @Command
Minimizes the active Notes/Domino window (the window whose title bar is highlighted).
Syntax
@Command( [WindowMinimize] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
Syntax
@Command( [WindowMinimizeAll] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
WindowNext @Command
Maximizes the Notes window whose taskbar button is to the right of the current windows taskbar
button or, if the windows are cascaded, moves the next window in the stack to the top of the stack.
Syntax
@Command( [WindowNext] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
WindowRestore @Command
Restores the active window to its former size (before it was maximized or minimized).
Syntax
@Command( [WindowRestore] )
Usage
This command can be used anywhere in Notes/Domino, except for an open dialog box. It does not work
on the Web.
If you use this command to restore a window that was maximized or minimized using
@Command([WindowMaximizeAll]) or @Command([WindowMinimizeAll]), only the current window is
restored, the other windows that were changed remain changed. You cannot use this command to restore
a cascaded or tiled window to its former size.
WindowTile @Command
Resizes all open Notes/Domino windows to display them all at once. The open windows are tiled across
the screen until they fill the background. If two windows are currently open, Notes displays them
side-by-side. If four windows are open, Notes displays one in each of the four quadrants of the window.
Syntax
@Command( [WindowTile] )
If you tile two or more windows, then close all but one of them, the remaining window does not readjust
its size. Use @Command([WindowMaximize]) to resize it to fit the screen.
WindowWorkspace @Command
Displays the Notes/Domino workspace as the active (topmost) window.
Syntax
@Command( [WindowWorkspace] )
Usage
This command can be used anywhere in Notes/Domino. It does not function in Web applications.
WorkspaceProperties @Command
Displays the Properties box for the Notes/Domino workspace.
Syntax
@Command( [WorkspaceProperties] )
Usage
The Notes/Domino workspace must be open in the current window. This command does not work on
the Web.
WorkspaceStackReplicaIcons @Command
For databases on the workspace that are replicas of one another, stacks them into a single icon. The
command is a toggle; selecting it a second time unstacks the replica icons and displays each icon
individually.
Syntax
@Command( [WorkspaceStackReplicaIcons] )
Usage
The Notes/Domino workspace must be open in the current window. This command does not work on
the Web.
ZoomPreview @Command
Toggles the ZoomPreview setting in a view.
Syntax
@Command( [ZoomPreview]; size )
Parameters
size
Usage
ZoomPreview enlarges the preview pane when enabled, and shrinks it when disabled. The preview pane
must be open. Using the 0 parameter is not the same as shrinking the window to its minimum size. The
window shrinks to its previous size; if the current size and previous size are the same, it does not shrink.
635
[DesignViewColumnDef] command [EditInsertTable] command [FileCloseWindow] command (continued)
formula language 510 formula language 524 Web programming 71
[DesignViewEditActions] command [EditInsertText] command [FileDatabaseACL] command
formula language 510 formula language 524 formula language 539
[DesignViewFormFormula] command [EditLeft] command [FileDatabaseCompact] command
formula language 511 formula language 525 formula language 539
[DesignViewNewColumn] command [EditLinks] command [FileDatabaseCopy] command
formula language 511 formula language 525 formula language 540
[DesignViews] command [EditLocations] command [FileDatabaseDelete] command
formula language 511 formula language 526 formula language 540
[DesignViewSelectFormula] command [EditMakeDocLink] command [FileDatabaseInfo] command
formula language 511 formula language 526 formula language 540
[DialingRules] command [EditNextField] command [FileDatabaseRemove] command
formula language 512 formula language 527 formula language 541
[Directories] command [EditOpenLink] command [FileDatabaseUseServer] command
formula language 512 formula language 527 formula language 541
[DiscoverFolders] command [EditPaste] command [FileExit] command
formula language 512 formula language 527 formula language 541
[EditBottom] command [EditPasteSpecial] command [FileExport] command
formula language 513 formula language 528 formula language 542
[EditButton] command [EditPhoneNumbers] command [FileFullTextCreate] command
formula language 513 formula language 528 formula language 543
[EditClear] command [EditPrevField] command [FileFullTextDelete] command
formula language 513 formula language 528 formula language 544
Web programming 71 [EditProfile] command [FileFullTextInfo] command
[EditCopy] command formula language 528 formula language 544
formula language 514 [EditProfileDocument] command [FileFullTextUpdate] command
[EditCut] command formula language 529 formula language 544
formula language 515 [EditQuoteSelection] command [FileImport] command
[EditDeselectAll] command formula language 530 formula language 544
formula language 515 [EditResizePicture] command [FileNewDatabase] command
[EditDetach] command formula language 531 formula language 546
formula language 516 [EditRestoreDocument] command [FileNewReplica] command
[EditDocument] command formula language 531 formula language 546
formula language 517 [EditRight] command [FileOpenDatabase] command
Web programming 71 formula language 532 formula language 546
[EditDown] command [EditSelectAll] command Web programming 71
formula language 517 formula language 532 [FileOpenDBRepID] command
[EditEncryptionKeys] command [EditSelectByDate] command formula language 548
formula language 518 formula language 533 [FilePageSetup] command
[EditFind] command [EditShowHideHiddenChars] command formula language 550
formula language 518 formula language 533 [FilePrint] command
[EditFindInPreview] command [EditTableDeleteRowColumn] command formula language 550
formula language 519 formula language 534 [FilePrintSetup] command
[EditFindNext] command [EditTableFormat] command formula language 552
formula language 519 formula language 534 [FileSave] command
[EditGotoField] command [EditTableInsertRowColumn] command formula language 552
formula language 519 formula language 535 Web programming 71
[EditHeaderFooter] command [EditTop] command [FileSaveNewVersion] command
formula language 520 formula language 535 formula language 553
[EditHorizScrollbar] command [EditUndo] command [FindFreeTimeDialog] command
formula language 520 formula language 535 formula language 553
[EditIndent] command [EditUntruncate] command [Folder] command
formula language 521 formula language 536 formula language 555
[EditIndentFirstLine] command [EditUp] command Web programming 71
formula language 521 formula language 536 [FolderCollapse] command
[EditInsertButton] command [EmptyTrash] command formula language 556
formula language 521 formula language 537 [FolderCustomize] command
[EditInsertFileAttachment] command Web programming 71 formula language 556
formula language 522 [ExchangeUnreadMarks] command [FolderDocuments] command
[EditInsertObject] command formula language 537 formula language 556
formula language 522 [Execute] command Web programming 71
[EditInsertPageBreak] command formula language 537 [FolderExpand] command
formula language 523 [ExitNotes] command formula language 557
[EditInsertPopup] command formula language 538 [FolderExpandAll] command
formula language 524 [FileCloseWindow] command formula language 557
formula language 538
Index 637
[SectionExpandAll] command [TextSetFontColor] command [UserIDInfo] command
formula language 594 formula language 606 formula language 618
[SectionProperties] command [TextSetFontFace] command [UserIDMergeCopy] command
formula language 594 formula language 607 formula language 619
[SectionRemoveHeader] command [TextSetFontSize] command [UserIDSetPassword] command
formula language 594 formula language 608 formula language 619
[SendInstantMessage] command [TextSpacingDouble] command [UserIDSwitch] command
formula language 595 formula language 608 formula language 619
[SetCurrentLocation] command [TextSpacingOneAndAHalf] command [V3EditNextField] command
formula language 595 formula language 609 formula language 620
[ShowHideIMContactList] command [TextSpacingSingle] command [V3EditPrevField] command
formula language 595 formula language 609 formula language 620
[ShowHideLinkPreview] command [TextUnderline] command [ViewArrangeIcons] command
formula language 595 formula language 609 formula language 620
[ShowHideParentPreview] command [ToolsCall] command [ViewBelowFolders] command
formula language 596 formula language 610 formula language 621
[ShowHidePreviewPane] command [ToolsCategorize] command [ViewBesideFolders] commnd
formula language 596 formula language 610 formula language 621
[ShowProperties] command [ToolsHangUp] command [ViewCertify] command
formula language 597 formula language 611 formula language 621
[SmartIconsFloating] command [ToolsMarkAllRead] command [ViewChange] command
formula language 597 formula language 611 formula language 622
[SmartIconsNextSet] command [ToolsMarkAllUnread] command Web programming 71
formula language 597 formula language 612 [ViewCollapse] command
[StyleCycleKey] command [ToolsMarkSelectedRead] command formula language 622
formula language 597 formula language 612 Web programming 71
[SwitchForm] command [ToolsMarkSelectedUnread] comand [ViewCollapseAll] command
formula language 598 formula language 612 formula language 623
[SwitchView] command [ToolsRefreshAllDocs] command Web programming 71
formula language 598 formula language 613 [ViewExpand] command
Web programming 71 [ToolsRefreshSelectedDocs] command formula language 623
[TextAlignCenter] command formula language 613 Web programming 71
formula language 599 [ToolsReplicate] command [ViewExpandAll] command
[TextAlignFull] command formula language 613 formula language 623
formula language 599 [ToolsRunBackgroundMacros] command Web programming 71
[TextAlignLeft] command formula language 614 [ViewExpandWithChildren] command
formula language 599 [ToolsRunMacro] command formula language 624
[TextAlignNone] command formula language 614 [ViewHorizScrollBar] command
formula language 600 Web programming 71 formula language 624
[TextAlignRight] command [ToolsScanUnreadChoose] command [ViewMoveName] command
formula language 600 formula language 615 formula language 624
[TextBold] command [ToolsScanUnreadPreferred] command [ViewNavigatorsFolders] command
formula language 601 formula language 615 formula language 625
[TextBullet] command [ToolsScanUnreadSelected] command [ViewNavigatorsNone] command
formula language 601 formula language 615 formula language 625
[TextCycleSpacing] command [ToolsSetupLocation] command [ViewRefreshFields] command
formula language 601 formula language 615 formula language 625
[TextEnlargeFont] command [ToolsSetupMail] command Web programming 71
formula language 602 formula language 616 [ViewRefreshUnread] command
[TextFont] command [ToolsSetupPorts] command formula language 626
formula language 602 formula language 616 [ViewRenamePerson] command
[TextItalic] command [ToolsSetupUserSetup] command formula language 626
formula language 603 formula language 616 [ViewShowFieldHelp] command
[TextNormal] command [ToolsSmartIcons] command formula language 626
formula language 603 formula language 616 [ViewShowObject] command
[TextNumbers] command [ToolsSpellCheck] command formula language 626
formula language 604 formula language 617 [ViewShowOnlyCategories] command
[TextOutdent] command [ToolsUserLogoff] command formula language 627
formula language 604 formula language 617 [ViewShowOnlySearchResults] command
[TextParagraph] command [UserIDCertificates] command formula language 627
formula language 604 formula language 617 [ViewShowOnlySelected] command
[TextParagraphStyles] command [UserIDClearPassword] command formula language 627
formula language 605 formula language 617 [ViewShowOnlyUnread] command
[TextPermanentPen] command [UserIDCreateSafeCopy] command formula language 628
formula language 605 formula language 618 [ViewShowPageBreaks] command
[TextReduceFont] command [UserIDEncryptionKeys] command formula language 628
formula language 606 formula language 618
Index 639
@Command([CreateFolder]) @Command([DesignViewColumnDef]) @Command([EditLocations])
formula language 501 formula language 510 formula language 526
@Command([CreateForm]) @Command([DesignViewEditActions]) @Command([EditMakeDocLink])
formula language 501 formula language 510 formula language 526
@Command([CreateLayoutRegion]) @Command([DesignViewFormFormula]) @Command([EditNextField])
formula language 501 formula language 511 formula language 527
@Command([CreateNavigator]) @Command([DesignViewNewColumn]) @Command([EditOpenLink])
formula language 502 formula language 511 formula language 527
@Command([CreatePolygon]) @Command([DesignViews]) @Command([EditPaste])
formula language 502 formula language 511 formula language 527
@Command([CreatePolyline]) @Command([DesignViewSelectFormula]) @Command([EditPasteSpecial])
formula language 502 formula language 511 formula language 528
@Command([CreateRectangle]) @Command([DialingRules]) @Command([EditPhoneNumbers])
formula language 502 formula language 512 formula language 528
@Command([CreateRectangularHotspot]) @Command([Directories]) @Command([EditPrevField])
formula language 503 formula language 512 formula language 528
@Command([CreateSection]) @Command([DiscoverFolders]) @Command([EditProfile])
formula language 503 formula language 512 formula language 528
@Command([CreateSubform]) @Command([EditBottom]) @Command([EditProfileDocument])
formula language 503 formula language 513 formula language 529
@Command([CreateTextbox]) @Command([EditButton]) @Command([EditQuoteSelection])
formula language 504 formula language 513 formula language 530
@Command([CreateView]) @Command([EditClear]) @Command([EditResizePicture])
formula language 504 formula language 513 formula language 531
@Command([DatabaseDelete]) @Command([EditCopy]) @Command([EditRestoreDocument])
formula language 504 formula language 514 formula language 531
@Command([DatabaseReplSettings]) @Command([EditCut]) @Command([EditRight])
formula language 505 formula language 515 formula language 532
@Command([DebugLotusScript]) @Command([EditDeselectAll]) @Command([EditSelectAll])
formula language 505 formula language 515 formula language 532
@Command([DesignDocumentInfo]) @Command([EditDetach]) @Command([EditSelectByDate])
formula language 505 formula language 516 formula language 533
@Command([DesignFormAttributes]) @Command([EditDocument]) @Command([EditShowHideHiddenChars])
formula language 506 formula language 517 formula language 533
@Command([DesignFormFieldDef]) @Command([EditDown]) @Command([EditTableDeleteRowColumn])
formula language 506 formula language 517 formula language 534
@Command([DesignFormNewField]) @Command([EditEncryptionKeys]) @Command([EditTableFormat])
formula language 506 formula language 518 formula language 534
@Command([DesignForms]) @Command([EditGotoField]) @Command([EditTableInsertRowColumn])
formula language 506 formula language 519 formula language 535
@Command([DesignFormShareField]) @Command([EditHeaderFooter]) @Command([EditTop])
formula language 507 formula language 520 formula language 535
@Command([DesignFormUseField]) @Command([EditHorizScrollbar]) @Command([EditUndo])
formula language 507 formula language 520 formula language 535
@Command([DesignFormWindowTitle]) @Command([EditIndent]) @Command([EditUntruncate])
formula language 507 formula language 521 formula language 536
@Command([DesignHelpAboutDocument]) @Command([EditIndentFirstLine]) @Command([EditUp])
formula language 507 formula language 521 formula language 536
@Command([DesignHelpUsingDocument]) @Command([EditInsertButton]) @Command([EmptyTrash])
formula language 508 formula language 521 formula language 537
@Command([DesignIcon]) @Command([EditInsertFileAttachment]) @Command([ExchangeUnreadMarks])
formula language 508 formula language 522 formula language 537
@Command([DesignMacros]) @Command([EditInsertObject]) @Command([Execute])
formula language 508 formula language 522 formula language 537
@Command([DesignRefresh]) @Command([EditInsertPageBreak]) @Command([ExitNotes])
formula language 508 formula language 523 formula language 538
@Command([DesignReplace]) @Command([EditInsertPopup]) @Command([FileCloseWindow])
formula language 509 formula language 524 formula language 538
@Command([DesignSharedFields]) @Command([EditInsertTable]) @Command([FileDatabaseACL])
formula language 509 formula language 524 formula language 539
@Command([DesignSynopsis]) @Command([EditInsertText]) @Command([FileDatabaseCompact])
formula language 509 formula language 524 formula language 539
@Command([DesignViewAppendColumn]) @Command([EditLeft]) @Command([FileDatabaseCopy])
formula language 509 formula language 525 formula language 540
@Command([DesignViewAttributes]) @Command([EditLinks]) @Command([FileDatabaseDelete])
formula language 510 formula language 525 formula language 540
Index 641
@Command([RemoteDebugLotusScript]) @Command([TextAlignCenter]) @Command([ToolsRefreshSelectedDocs])
formula language 587 formula language 599 formula language 613
@Command([RemoveFromFolder]) @Command([TextAlignFull]) @Command([ToolsReplicate])
formula language 587 formula language 599 formula language 613
@Command([RenameDatabase]) @Command([TextAlignLeft]) @Command([ToolsRunBackgroundMacros])
formula language 588 formula language 599 formula language 614
@Command([Replicator]) @Command([TextAlignNone]) @Command([ToolsRunMacro])
formula language 589 formula language 600 formula language 614
@Command([ReplicatorReplicateHigh]) @Command([TextAlignRight]) @Command([ToolsScanUnreadChoose])
formula language 589 formula language 600 formula language 615
@Command([ReplicatorReplicateNext]) @Command([TextBold]) @Command([ToolsScanUnreadPreferred])
formula language 589 formula language 601 formula language 615
@Command([ReplicatorReplicateSelected]) @Command([TextBullet]) @Command([ToolsScanUnreadSelected])
formula language 590 formula language 601 formula language 615
@Command([ReplicatorReplicateWithServer]) @Command([TextCycleSpacing]) @Command([ToolsSetupLocation])
formula language 590 formula language 601 formula language 615
@Command([ReplicatorSendMail]) @Command([TextEnlargeFont]) @Command([ToolsSetupMail])
formula language 590 formula language 602 formula language 616
@Command([ReplicatorSendReceiveMail]) @Command([TextFont]) @Command([ToolsSetupPorts])
formula language 590 formula language 602 formula language 616
@Command([ReplicatorStart]) @Command([TextItalic]) @Command([ToolsSetupUserSetup])
formula language 591 formula language 603 formula language 616
@Command([ReplicatorStop]) @Command([TextNormal]) @Command([ToolsSmartIcons])
formula language 591 formula language 603 formula language 616
@Command([RunAgent]) @Command([TextNumbers]) @Command([ToolsSpellCheck])
formula language 591 formula language 604 formula language 617
@Command([RunScheduledAgents]) @Command([TextOutdent]) @Command([ToolsUserLogoff])
formula language 592 formula language 604 formula language 617
@Command([SectionCollapse]) @Command([TextParagraph]) @Command([UserIDCertificates])
formula language 592 formula language 604 formula language 617
@Command([SectionCollapseAll]) @Command([TextParagraphStyles]) @Command([UserIDClearPassword])
formula language 593 formula language 605 formula language 617
@Command([SectionDefineEditors]) @Command([TextPermanentPen]) @Command([UserIDCreateSafeCopy])
formula language 593 formula language 605 formula language 618
@Command([SectionExpand]) @Command([TextReduceFont]) @Command([UserIDEncryptionKeys])
formula language 593 formula language 606 formula language 618
@Command([SectionExpandAll]) @Command([TextSetFontColor]) @Command([UserIDInfo])
formula language 594 formula language 606 formula language 618
@Command([SectionProperties]) @Command([TextSetFontFace]) @Command([UserIDMergeCopy])
formula language 594 formula language 607 formula language 619
@Command([SectionRemoveHeader]) @Command([TextSetFontSize]) @Command([UserIDSetPassword])
formula language 594 formula language 608 formula language 619
@Command([SendInstantMessage]) @Command([TextSpacingDouble]) @Command([UserIDSwitch])
formula language 595 formula language 608 formula language 619
@Command([SetCurrentLocation]) @Command([TextSpacingOneAndAHalf]) @Command([V3EditNextField])
formula language 595 formula language 609 formula language 620
@Command([ShowHideIMContactList]) @Command([TextSpacingSingle]) @Command([V3EditPrevField])
formula language 595 formula language 609 formula language 620
@Command([ShowHideLinkPreview]) @Command([TextUnderline]) @Command([ViewArrangeIcons])
formula language 595 formula language 609 formula language 620
@Command([ShowHideParentPreview]) @Command([ToolsCall]) @Command([ViewBelowFolders])
formula language 596 formula language 610 formula language 621
@Command([ShowHidePreviewPane]) @Command([ToolsCategorize]) @Command([ViewBesideFolders])
formula language 596 formula language 610 formula language 621
@Command([ShowProperties]) @Command([ToolsHangUp]) @Command([ViewCertify])
formula language 597 formula language 611 formula language 621
@Command([SmartIconsFloating]) @Command([ToolsMarkAllRead]) @Command([ViewChange])
formula language 597 formula language 611 formula language 622
@Command([SmartIconsNextSet]) @Command([ToolsMarkAllUnread]) @Command([ViewCollapse])
formula language 597 formula language 612 formula language 622
@Command([StyleCycleKey]) @Command([ToolsMarkSelectedRead]) @Command([ViewCollapseAll])
formula language 597 formula language 612 formula language 623
@Command([SwitchForm]) @Command([ToolsMarkSelectedUnread]) @Command([ViewExpand])
formula language 598 formula language 612 formula language 623
@Command([SwitchView]) @Command([ToolsRefreshAllDocs]) @Command([ViewExpandAll])
formula language 598 formula language 613 formula language 623
Index 643
@FloatEq function @IsDocBeingMailed function @MailSavePreference function
formula language 154, 300 formula language 161, 324 formula language 355
@FontList function @IsDocBeingRecalculated function @MailSend function
formula language 300 formula language 161, 325 defined 161
@For function @IsDocBeingSaved function formula language 355
formula language 139, 301 formula language 161, 326 side-effects 127
@FormLanguage function @IsDocTruncated function @MailSignPreference function
formula language 303 formula language 326, 327 formula language 358
@Functions @IsError function @Matches function
@commands 127 formula language 144, 328 formula language 149, 359
described 126 @IsExpandable function @Max function
order of evaluation 128 formula language 160, 329 formula language 154, 361
reference 167 @IsMember function @Member function
return values 126 formula language 135, 330 formula language 135, 362
side-effects 127 @IsModalHelp function @Middle function
syntax 126 formula language 331 formula language 151, 363
Web programming 68 @IsNewDoc function @MiddleBack function
@GetAddressBooks function formula language 161, 331 formula language 151, 364
formula language 303 @IsNotMember function @Min function
@GetCurrentTimeZone function formula language 135, 332 formula language 154, 365
formula language 304 @IsNull function @Minute function
@GetDocField function formula language 333 formula language 156, 366
formula language 164, 304 @IsNumber function @Modified function
@GetField function formula language 148, 334 formula language 156, 367
formula language 305 @IsResponseDoc function @Modulo function
@GetFocusTable function formula language 161, 335 formula language 154, 367
formula language 161, 306 @IsText function @Month function
@GetHTTPHeader function formula language 148, 335 formula language 156, 368
formula language 307 @IsTime function @Name function
Web programming 68 formula language 148, 336 formula language 158, 369
@GetIMContactListGroupNames function @IsUnavailable function @NameLookup function
formula language 308 formula language 161, 337 formula language 374
@GetPortsList function @IsValid function @Narrow function
formula language 309 formula language 337 formula language 376
@GetProfileField function @IsVirtualizedDirectory function @NewLine function
formula language 309 formula language 338 formula language 153, 376
@GetViewInfo function @Keywords function @No function
formula language 311 formula language 135, 338 formula language 377
@HardDeleteDocument function @LanguagePreference function @NoteID function
formula language 312 formula language 340 formula language 161, 378
@HashPassword function @LaunchApp function @Nothing function
formula language 312 formula language 342 formula language 135, 378
@Hour function @LDAPServer function @Now function
formula language 156, 313 formula language 342 formula language 156, 379
@If function @Left function @OptimizeMailAddress function
formula language 128, 138, 314 formula language 151, 342 formula language 158, 380
@IfError function @LeftBack function @OrgDir function
formula language 144, 315 formula language 151, 343 formula language 381
@Implode function @Length function @Password function
formula language 135, 316 formula language 149, 344 formula language 158, 381
@InheritedDocumentUniqueID function @Like function @PasswordQuality function
formula language 161, 317 formula language 149, 345 formula language 382
@Integer function @Ln function @Pi function
formula language 154, 318 formula language 154, 346 formula language 154, 382
@IsAgentEnabled function @Locale function @PickList function
formula language 319 formula language 346 formula language 383
@IsAppInstalled function @Log function getting user input with 141
formula language 320 formula language 154, 351 side-effects 127
@IsAvailable function @LowerCase function @Platform function
formula language 161, 320 formula language 153, 352 formula language 158, 386
@IsCategory function @MailDbName function @PolicyIsFieldLocked function
formula language 160, 321 formula language 158, 352 formula language 388
@IsDocBeingEdited function @MailEncryptSavedPreference function @PostedCommand function
formula language 161, 208, 322, 323 formula language 353 defined 147
@IsDocBeingLoaded function @MailEncryptSentPreference function formula language 127, 388
formula language 161, 324 formula language 354 side-effects 127
Index 645
Access levels AdminOpenServerLog command Angles
formula language 261, 452, 459, 461 formula language 485 calculating in formula language 204,
reading 452 AdminOpenServersView command 212, 213, 231, 419, 425
Accessed function formula language 485 Applets array
formula language 156, 203 AdminOpenStatistics command JavaScript 86
Accessibility formula language 485 Applications
LotusScript debugger 55 AdminOpenUsersView command launching in formula language 342,
programmers pane 37, 40, 42, 43, 44 formula language 486 491, 537
ACL AdminOutgoingMail command testing existence of in formula
database 539 formula language 486 language 320
editing 539 AdminRegisterFromFile command Arguments
populating a column with 12 formula language 487 Web programming 79
Acos function AdminRegisterServer command Arithmetic operators
formula language 154, 204 formula language 487 formula language 123, 154
Action scripts and formulas AdminRegisterUser command Ascii function
formula language 134 formula language 487 formula language 211
Actions AdminRemoteConsole command Asin function
coding 7 formula language 487 formula language 154, 212
creating 500 AdminSendMailTrace command ASP environment
AddBookmark command formula language 488 accessing organization directories
formula language 477 AdminStatisticsConfig command in 381
AddDatabase command formula language 488 Assignment operators
formula language 478 AdminTraceConnection command formula language 120, 121
AddDatabaseRepID command formula language 488 Atan function
formula language 479 AgentEdit command formula language 154, 212
Addition formula language 489 Atan2 function
formula language 154 AgentEnableDisable command formula language 154, 213
Addition operator (+) formula language 489 AttachmentDetachAll command
formula language 120 AgentLog command formula language 491
AddToFolder function formula language 489 AttachmentLaunch command
formula language 205 AgentRun command formula language 491
AddToIMContactList command formula language 490 AttachmentLengths function
formula language 479 Agents formula language 161, 214
Adjust function Web programming 79 AttachmentModifiedTimes function
formula language 156, 206 Agents, types of formula language 161, 215
AdminCertify command running on the Web 71 AttachmentNames function
formula language 480 scheduled 490 formula language 161, 216
AdminCreateGroup command Agents, working with AttachmentProperties command
formula language 480 checking status of in formula formula language 492
AdminCrossCertifyIDFile command language 319 Attachments
formula language 480 coding 5, 134 creating 522
AdminCrossCertifyKey command creating 500 deleting highlighted 495, 513, 515
formula language 481 debugging 57, 489 detaching. See saving 516
AdminDatabaseAnalysis command editing a Java agent 47 editing in Designer 492, 597
formula language 481 editing in formula language 489 getting details of in formula
AdminDatabaseQuotas command enabling/disabling 489 language 214, 215, 216, 217
formula language 481 running 490, 591, 592, 614 launching 491
AdminIDFileClearPassword command running on the Web 490, 614 saving 491, 516
formula language 482 viewing the log 489, 490, 491 viewing 492
AdminIDFileExamine command AgentSetServerName command Attachments function
formula language 482 formula language 490 formula language 161, 217
AdminIDFileSetPassword command AgentTestRun command AttachmentView command
formula language 482 formula language 491 formula language 492
Administration command Alarms Author function
formula language 482 checking 225 formula language 161, 217
AdminNewOrganization command enabling 289 Authors
formula language 483 All function 5, 12 getting list of in formula
AdminNewOrgUnit command formula language 133, 208 language 217
formula language 483 AllChildren function Auto complete
AdminOpenAddressBook command formula language 146, 161, 209 in script area of programmers
formula language 483 AllDescendants function pane 45
AdminOpenCatalog command formula language 161, 209 properties 45
formula language 484 Alternate names
AdminOpenCertLog command getting in formula language 454
formula language 484
AdminOpenGroupsView command
AND operator
formula language 120
B
Backslash (
formula language 484
)\formula language 117
Index 647
Currency Date and time handling (continued) Debugging (continued)
converting to text in formula reading in formula language 235, formula language 130
language 426 313, 366, 368, 379, 405, 431, 435, 436, Java 59
Current document 471, 472 LotusScript 53, 57, 505, 587
formula language 161 setting in formula language 206 LotusScript debugger controls 54
Custom controls Date function DebugLotusScript command
adding to forms 522 formula language 156, 234 formula language 505
Dates Decimals
formula language 118 formula language 118
D performing calculations on in formula
language 206
Default reserved word
formula language 161, 268
Data types
Day function DEFAULT reserved word
@functions 126, 437
formula language 156, 235 formula language 129
determining in formula
DbColumn function Default validation formulas
language 334, 335, 336
formula language 164 coding 133
formula language 114
ODBC 166 Default value formulas
Database access
side-effects 127 coding 19, 133
getting details of in formula
DbColumn(Notes data source) function Deftype statement
language 261, 452
formula language 237 in script area of programmers
troubleshooting 539
DbColumn(ODBC data source) function pane 51
Database design
formula language 240 DeleteDocument function
creating synopsis 509
DbCommand function formula language 269
refreshing 508
formula language 166 DeleteField function
replacing template 509
Web programming 68 formula language 161, 269
Database names
DbCommand function(Domino data Deletions
getting URL encoded in formula
source) restoring with formula language 442,
language 467
formula language 245 531
Web programming 68
DbCommand function(ODBC data Design elements
Database performance
source) table of programmable objects 2
troubleshooting 481
formula language 246 Design synopsis
DatabaseDelete command
DBCS creating 509
formula language 504
formula language 376 DesignDocumentInfo command
DatabaseReplSettings command
DbExists function formula language 505
formula language 505
formula language 250 DesignFormAttributes command
Databases
DbLookup function formula language 506
access control lists 539
Notes database 164 DesignFormFieldDef command
accessing 160, 400, 541
ODBC 166 formula language 506
adding to a library 584
side-effects 127 DesignFormNewField command
changing 539
DbLookup(Notes data source) function formula language 506
compacting 539
formula language 251 DesignForms command
copying 540
DbLookup(ODBC data source) function formula language 506
creating 546
formula language 256 DesignFormShareField command
creating bookmarks for 478
DbManager function formula language 507
deleting 504, 540, 541
formula language 160, 261 DesignFormUseField command
extracting data from in formula
DbName function formula language 507
language 237, 240, 245, 246, 251,
formula language 160, 262 DesignFormWindowTitle command
256
DbTitle function formula language 507
getting details of in formula
formula language 160, 263 DesignHelpAboutDocument command
language 262, 263, 481, 540
DDE formula language 507
icons 478, 479, 508, 620, 626, 629, 632
formula language 264, 265, 267 DesignHelpUsingDocument command
indexing 543, 544
DDEExecute function formula language 508
opening 546, 548
formula language 264 DesignIcon command
print settings 550
side-effects 127 formula language 508
replicating 505, 541, 546, 613
DDEInitiate function DesignMacros command
size limits 481
formula language 265 formula language 508
statistics 481, 485
side-effects 127 DesignRefresh command
switching replicas 588
DDEPoke function formula language 508
templates 508, 509
formula language 267 DesignReplace command
testing existence of in formula
side-effects 127 formula language 509
language 250
DDETerminate function DesignSharedFields command
titling 546
formula language 267 formula language 509
unread marks 615
side-effects 127 DesignSynopsis command
Date and time handling
Debug console formula language 509
converting in formula language 234,
Java 39 DesignViewAppendColumn command
426, 429, 431, 433, 438, 467
Debugging formula language 509
formula language 156, 433
a script 505 DesignViewAttributes command
getting business days in formula
agents 57 formula language 510
language 221
Index 649
EditGotoField command EditTableInsertRowColumn command Examples (continued)
formula language 519 formula language 535 getting and setting environment
EditHeaderFooter command EditTop command variables 143
formula language 520 formula language 535 getting user input with @Prompt 142
EditHorizScrollbar command EditUndo command hidden paragraph formula 15
formula language 520 formula language 535 HTML attributes formula 20
EditIndent command EditUntruncate command input enabled formula 20
formula language 521 formula language 536 input translation formula 19
EditIndentFirstLine command EditUp command input validation formula 19
formula language 521 formula language 536 insert subform formula 14
EditInsertButton command EditUserECL function keyword field formula 20
formula language 521 formula language 288 locating and extracting substring 152
EditInsertFileAttachment command Elements function performing time-date operation 158
formula language 522 formula language 135, 288 repeating 153
EditInsertObject command EmptyTrash command run-time errors 145
formula language 522 formula language 537 section access formula 14
EditInsertPageBreak command Web programming 71 section title formula 14
formula language 523 EnableAlarms function selection formula 12
EditInsertPopup command formula language 289 SmartIcons 4
formula language 524 Ends function trimming 153
EditInsertTable command formula language 151, 289 user environment 159
formula language 524 Environment function using a conditional statement 139
EditInsertText command formula language 146, 290 value formula 20
formula language 524 Environment reserved word window title formula 13
EditLeft command formula language 290 working with a list 136
formula language 525 ENVIRONMENT reserved word writing a button script or formula 10
EditLinks command formula language 129 writing a default value formula 19
formula language 525 Environment variables writing a replication formula 5
EditLocations command formula language 143, 290, 412 writing a script and a formula 17
formula language 526 Equals operator (=) writing a script for an action 8
EditMakeDocLink command formula language 120 writing a script for an agent 6
formula language 526 Error function writing an @function with a
EditNextField command formula language 144, 293 result 134
formula language 527 Error handling writing an action formula 135
EditOpenLink command compiling LotusScript 52 writing formula for an agent 6
formula language 527 formula language 144, 293, 315, 328 writing message with @Prompt 141
EditPaste command LotusScript 52 writing script/formula for an
formula language 527 Error messages action 8
EditPasteSpecial command customizing 315 ExchangeUnreadMarks command
formula language 528 Errors box formula language 537
EditPhoneNumbers command defined 37 Execute command
formula language 528 programmers pane 42 formula language 537
EditPrevField command Eval function ExitNotes command
formula language 528 formula language 294 formula language 538
EditProfile command Events Exp function
formula language 528 coding 17 formula language 154, 295
EditProfileDocument command compatibility issues 21 Explode function
formula language 529 defined 21 formula language 135, 295
EditQuoteSelection command JavaScript 83 Export button
formula language 530 sequencing 33 Java 39
EditResizePicture command Sequencing 33 Exporting
formula language 531 user interface 41 files 542
EditRestoreDocument command Examples
formula language 531 accessing an external database 166
EditRight command
formula language 532
accessing outside data 165
accessing the current database and
F
Failure function
EditSelectAll command view 161
formula language 146, 297
formula language 532 accessing the current document 163
False function
EditSelectByDate command adding a new line 153
formula language 297
formula language 533 arithmetic operation 155
Field design formulas
EditShowHideHiddenChars command changing case 153
coding 19
formula language 533 concatenating 150
Field keyword
EditTableDeleteRowColumn command converting a data type 149
formula language 116
formula language 534 filling out form with
Field reserved word
EditTableFormat command @DialogBox 143
formula language 161, 298
formula language 534 form formula 12
FIELD reserved word
formula language 129
Index 651
Frames (continued) HashPassword function Imported Java
refreshing on the Web 71 formula language 312 interface elements 39
specifying a target frame in formula Headers Importing
language 416 editing 520 Java into the programmers pane 49
Frames array Help Index operator
JavaScript 86 for fields 626 formula language 120, 122
Framesets opening on the Web 71 Info field
editing in Designer 597 triggering for an application 580 formula language 114
opening 580 HelpAboutDatabase command Info List
opening on the Web 71 formula language 560 using 40
refreshing 586, 587 HelpAboutNotes command InheritedDocumentUniqueID function
Full-text indexes formula language 560 formula language 161, 317
creating 543 HelpRequest event Initialize event
deleting 544 table of events 21 Sequencing 33
infomation 544 HelpUsingDatabase command table of events 21
updating 544 formula language 560 Input enabled formulas
Function block Hidden column formulas coding 20
in script area of programmers coding 15 Input translation formulas
pane 51 Hidden object coding 19, 133
Functions JavaScript 86 Input validation formulas
@function syntax 126 Hidden paragraph formulas coding 19
coding 15, 133 formula language 297, 424
Hide action formulas Insert subform formulas
G coding 7
Hierarchical names
coding 14, 133
Insertion point
GetAddressBooks function
converting in formula language 369 setting in documents 513, 517, 519,
formula language 303
History object 525, 527, 528, 532, 535, 536, 620
GetCurrentTimeZone function
JavaScript 86 InsertSubForm command
formula language 304
HotSpotClear command formula language 561
GetDocField function
formula language 560 Instant messaging
formula language 164, 304
HotSpotProperties command formula language 308, 479, 595
GetField function
formula language 561 Integer function
formula language 305
Hotspots formula language 154, 318
GetFocusTable function
coding 9, 133 Integers
formula language 161, 306
creating 503, 524 formula language 118
GetHTTPHeader function
editing in Designer 561, 597 Internet addresses
formula language 307
pop-ups 524 validating in formula language 462
Web programming 68
removing 560 IsAgentEnabled function
GetIMContactListGroupNames function
Hour function formula language 319
formula language 308
formula language 156, 313 IsAppInstalled function
GetPortsList function
HTML formula language 320
formula language 309
using JavaScript in 84 IsAvailable function
GetProfileField function
HTML attributes formulas formula language 161, 320
formula language 309
coding 20 IsCategory function
GetViewInfo function
HTTP headers formula language 160, 321
formula language 311
formula language 307, 414, 446 IsDocBeingEdited function
Global variables
formula language 161, 208, 322, 323
defining 51
IsDocBeingLoaded function
GoUpLevel command
formula language 559 I formula language 161, 324
IsDocBeingMailed function
Graphics Icons
formula language 161, 324
adding to layout regions 561 arranging 620
IsDocBeingRecalculated function
editing in Designer 584, 597 deleting 513, 515
formula language 161, 325
resizing in formula language 531 editing 508, 629
IsDocBeingSaved function
Greater than operator (>) stacking database 632
formula language 161, 326
formula language 120 unread count 626, 629
IsDocTruncated function
Greater than or equal to operator (>= or If function
formula language 326, 327
=>) formula language 128, 138, 314
IsError function
formula language 120 IfError function
formula language 144, 328
Groups formula language 144, 315
IsExpandable function
creating 480 Image formulas
formula language 160, 329
coding 16
IsMember function
Images array
formula language 135, 330
H JavaScript 86
Implode function
IsModalHelp function
HardDeleteDocument function formula language 331
formula language 135, 316
formula language 312 IsNewDoc function
Import Class Files button
formula language 161, 331
Imported Java 39
Index 653
MailRequestCrossCert command
formula language 565
N NavNextSelected command
formula language 574
MailRequestNewName command Name function NavNextUnread command
formula language 565 formula language 158, 369 formula language 575
MailRequestNewPublicKey command Named elements NavPrev command
formula language 565 coding 15 formula language 575
MailSavePreference function NameLookup function Web programming 71
formula language 355 formula language 374 NavPrevMain command
MailScanUnread command Names formula language 576
formula language 566 getting User in formula Web programming 71
MailSend command language 454 NavPrevSelected command
formula language 566 Narrow function formula language 576
MailSend function formula language 376 NavPrevUnread command
defined 161 NavigateNext command formula language 577
formula language 355 formula language 568 Negation operator (-)
side-effects 127 Web programming 71 formula language 120
MailSendCertificateRequest command NavigateNextHighlight command Negative numbers
formula language 566 formula language 568 formula language 118
MailSendEncryptionKey command NavigateNextMain command New Class button
formula language 566 formula language 569 Java 39
MailSendPublicKey command Web programming 71 NewLine function
formula language 567 NavigateNextSelected command formula language 153, 376
MailSignPreference function formula language 569 No function
formula language 358 NavigateNextUnread command formula language 377
Matches function formula language 570 NoExternalApps
formula language 149, 359 NavigatePrev command environment variable 127
Max function formula language 570 Not equal to operator
formula language 154, 361 Web programming 71 formula language 120
Member function NavigatePrevHighlight command Not operator
formula language 135, 362 formula language 571 formula language 120
Memos NavigatePrevMain command NoteID function
creating a default mail document 563 formula language 571 formula language 161, 378
Message Web programming 71 Notes client
Web services 91 NavigatePrevSelected command exiting 538, 541
Messages formula language 571 getting details of in formula
writing in formula language 140, 423 NavigatePrevUnread command language 560
Middle function formula language 572 startup settings 616
formula language 151, 363 NavigateToBacklink command notes.ini file
MiddleBack function formula language 572 formula language 129, 143
formula language 151, 364 Navigation pane retrieving path to 230
Min function editing 556, 557, 558 Nothing function
formula language 154, 365 Navigator object formula language 135, 378
Minus operator (-) JavaScript 86 Now function
formula language 123 Navigator pane formula language 156, 379
Minus sign displaying 621 Null fields
formula language 118 hiding 625 formula language 114, 333
Minute function opening views/folders in 625 Number handling
formula language 156, 366 NavigatorProperties command formula language 295, 300, 318, 346,
Modems formula language 572 351, 361, 365, 367, 389, 404, 418, 422,
settings 512 Navigators 424
Modified function adding objects to 500, 502, 503, 504 Number lists
formula language 156, 367 creating 502 finding largest number in with
Modulo function designing 500, 502, 504 formula language 361
formula language 154, 367 editing in Designer 572, 597 finding smallest number in with
Month function graphics and 584 formula language 365
formula language 156, 368 hotspots and 584 Numbers
MoveToTrash command opening 582 comparing in formula language 300
formula language 567 opening on the Web 71 converting to time-date in formula
Web programming 71 testing 573 language 234
Multiplication operator (*) NavigatorTest command generating random in formula
formula language 120 formula language 573 language 394
Multiplying NavNext command rounding 404
formula language 154 formula language 573 verifying data type in formula
Web programming 71 language 334
NavNextMain command Numeric constants
formula language 574 formula language 118
Web programming 71
Index 655
PostModeChange event
table of events 21
Q Remote debugger
Java 59
PostOpen event QueryAddToFolder event Remote Debugger
table of events 21 table of events 21 LotusScript 57
PostPaste event QueryClose event RemoteDebugLotusScript @command
table of events 21 table of events 21 formula language 587
PostRecalc event QueryDocumentDelete event RemoveFromFolder command
table of events 21 table of events 21 formula language 587
PostSave event QueryDocumentUndelete event Web programming 71
table of events 21 table of events 21 RenameDatabase command
PostSend event QueryDragDrop event formula language 588
table of events 21 table of events 21 Renaming
Power function QueryEntryResize event in script area of programmers
formula language 154, 389 table of events 21 pane 45
Precedence of operators QueryModeChange event Repeat function
formula language 120 table of events 21 formula language 153, 397
Preferences file QueryOpen event Replace function
formula language 129 table of events 21 formula language 135, 398
Previewing QueryOpenDocument event ReplaceSubstring function
documents 632 table of events 21 formula language 399
Primary names QueryPaste event ReplicaID function
extracting in formula language 454 table of events 21 formula language 160, 400
Print command 550 QueryRecalc event Replicas
Print setup table of events 21 choosing database 541
formula language 550, 552 QuerySend event Replication
Profile documents table of events 21 initializing 589, 590, 591
creating 528, 529 Quotation marks settings 505
editing 528, 529 formula language 117 specifying server 590
retrieving fields from in formula stopping 589, 591
language 309 Replication formulas
setting field values in with formula R coding 5, 133
language 415 Radio object Replicator command
Programmable design elements JavaScript 86 formula language 589
table 2 Random function ReplicatorReplicateHigh command
Programmers pane formula language 154, 394 formula language 589
accessing 37 Redundant spaces ReplicatorReplicateNext command
defined 37 removing in formula language 440 formula language 589
Java 39 Reference list ReplicatorReplicateSelected command
JavaScript 49 defined 37 formula language 590
properties 43 Reference tab ReplicatorReplicateWithServer command
properties and events 41 defined 37 formula language 590
Programming in programmers pane 42 ReplicatorSendMail command
Auto complete 45 RefreshECL function formula language 590
LotusScript programming formula language 395 ReplicatorSendReceiveMail command
environment 37 RefreshFrame command formula language 590
overview 1 formula language 585 ReplicatorStart command
Web 67 Web programming 71 formula language 591
Prompt function RefreshHideFormulas command ReplicatorStop command
formula language 390 formula language 586 formula language 591
getting user input with 141 RefreshParentNote command Response documents
side-effects 127 formula language 586 creating 498
writing messages with 140 RefreshWindow command previewing parent 596
ProperCase function formula language 586 properties 273
formula language 153, 393 RegionDoubleClick event Responses function
Properties table of events 21 formula language 160, 161, 400
user interface 41 Registry keys Return function
Property block querying in formula language 395 formula language 128, 146, 401
in script area of programmers RegQueryValue function Return values
pane 51 formula language 395 @functions 126
Public keys ReloadWindow command Rich text fields
extracting data from in formula formula language 587 formula language 114, 528, 532, 533
language 222 Rem directive Rich text paragraph styles
PublishDatabase command %Rem in script area of programmers formula language 521
formula language 584 pane 52 Right function
REM reserved word formula language 151, 402
formula language 129, 396 RightBack function
formula language 151, 403
Index 657
String handling (continued) Text TextNormal command
replacing in formula language 399 abstracting from with formula formula language 603
trimming in formula language 440 language 197 TextNumbers command
Strings adding to layout regions 562 formula language 604
encoding in formula language 312, aligning 599, 600, 604 TextOutdent command
381, 464 coloring 605, 606 formula language 604
formula language 148 copying highlighted 514 TextParagraph command
StyleCycleKey command deleting highlighted 495, 513, 515 formula language 604
formula language 597 editing in script area of programmers TextParagraphStyles command
Styles pane 44 formula language 605
cycling through assigned 597 font 602, 607 TextPermanentPen command
Sub block formatting for Internet 530 formula language 605
in script area of programmers inserting programmatically 524 TextReduceFont command
pane 51 pasting in formula language 527, 528 formula language 606
Subforms properties in programmers pane 43 TextSetFontColor command
creating 503 searching for 518, 519 formula language 606
editing in Designer 506 sizing 602, 606, 608 TextSetFontFace command
inserting 14, 561 spacing 601, 608, 609 formula language 607
Subprograms styling 601, 603, 609 TextSetFontSize command
defining 51 text constants in formula formula language 608
selecting in LotusScript debugger 54 language 117 TextSpacingDouble command
Subscript operator verifying data type in formula formula language 608
formula language 120, 122 language 335 TextSpacingOneAndAHalf command
Subset function Text function formula language 609
formula language 135, 423 formula language 148, 426 TextSpacingSingle command
Substrings Text lists formula language 609
formula language 151 comparing in formula language 228 TextToNumber function
Subtraction concatenating in formula formula language 428
formula language 154 language 294, 316 TextToTime function
Subtraction operator (-) extracting from 470 formula language 429
formula language 120 extracting from in formula TextUnderline command
Success function language 423 formula language 609
formula language 146, 424 finding and replacing in with formula ThisName function
Web programming 68 language 398, 399 formula language 430
Sum function finding keywords in with formula ThisValue function
formula language 154, 424 language 330, 332, 338 formula language 431
SwitchForm command removing duplicates in with formula Time
formula language 598 language 442 formula language 118
SwitchView command styling 601, 604 Time function
formula language 598 Text object formula language 156, 431
Web programming 71 JavaScript 86 Time zones
Syntax errors Text operator specifying 304, 434
formula language 144 formula language 123 Time-dates
TextAlignCenter command verifying data type in formula
formula language 599 language 336
T TextAlignFull command
formula language 599
TimeMerge function
formula language 433
Tables
TextAlignLeft command TimeToTextInZone function
columns 534, 535
formula language 599 formula language 433
creating 524
TextAlignNone command TimeZoneToText function
deleting highlighted 495, 513, 515
formula language 600 formula language 434
editing in formula language 534
TextAlignRight command Title bar
name and column information in
formula language 600 defined 37
formula language 306
TextArea object Title field
rows 534, 535
JavaScript 86 formula language 114
Tabs
TextBold command Today function
inserting with formula language 223
formula language 601 formula language 156, 435
showing/hiding in formula
TextBullet command Tomorrow function
language 533
formula language 601 formula language 156, 436
Tan function
TextCycleSpacing command ToNumber function
formula language 154, 425
formula language 601 formula language 437
TemplateVersion function
TextEnlargeFont command Toolbars
formula language 426
formula language 602 using and customizing 3, 616
Temporary variables
TextFont command ToolsCall command
formula language 116, 410
formula language 602 formula language 610
Terminate event
TextItalic command ToolsCategorize command
table of events 21
formula language 603 formula language 610
Index 659
ViewCollapse command (continued) ViewShowFieldHelp command Window (continued)
Web programming 71 formula language 626 resizing 630, 631
ViewCollapseAll command ViewShowObject command switching 631
formula language 623 formula language 626 Window object
Web programming 71 ViewShowOnlyCategories command JavaScript 86
ViewExpand command formula language 627 Window title formulas
formula language 623 ViewShowOnlySearchResults command coding 13, 133, 160, 507
Web programming 71 formula language 627 WindowCascade command
ViewExpandAll command ViewShowOnlySelected command formula language 630
formula language 623 formula language 627 WindowMaximize command
Web programming 71 ViewShowOnlyUnread command formula language 630
ViewExpandWithChildren command formula language 628 WindowMaximizeAll command
formula language 624 ViewShowPageBreaks command formula language 630
ViewHorizScrollBar command formula language 628 WindowMinimize command
formula language 624 ViewShowRuler command formula language 630
ViewMoveName command formula language 628 WindowMinimizeAll command
formula language 624 ViewShowSearchBar command formula language 631
ViewNavigatorsFolders command formula language 628 WindowNext command
formula language 625 Web programming 71 formula language 631
ViewNavigatorsNone command ViewShowServerNames command WindowRestore command
formula language 625 formula language 629 formula language 631
ViewRefreshFields command ViewShowThisUnread function Windows registry
formula language 625 formula language 465 querying in formula language 395
Web programming 71 ViewShowUnread command WindowTile command
ViewRefreshUnread command formula language 629 formula language 631
formula language 626 ViewSwitchForm command WindowTitle field
ViewRenamePerson command formula language 629 formula language 114
formula language 626 ViewTitle function WindowWorkspace command
Views formula language 146, 160, 466 formula language 632
collapsing 622, 623 Virtualized directories Word function
columns in 509, 511 formula language 338 formula language 151, 470
creating 504 Workspace
designing 511 displaying 632
documents and 527
editing in Designer 510, 597
W editing in Designer 597, 632
stacking icons 632
Web agents
expanding 623, 624 WorkspaceProperties command
creating 79
expanding on the Web 71 formula language 632
Web programming environment 67
exporting 542 WorkspaceStackReplicaIcons command
Web services
filtering in formula language 417, formula language 632
design element 92
627, 628 WSDL
invoking 95
getting details of in formula Web Services Description
LotusScript and Java mappings 95
language 311, 466 Language 91
overview 91
importing files into 544
terminology 91
naming in a formula 130
WebDbName function
navigating through documents
in 568, 569, 570, 571, 572, 573, 574,
Web programming 68 Y
WebDBName function Year function
575, 576, 577
formula language 467 formula language 156, 471
opening 583
WebQueryOpen events Yes function
opening on the Web 71
table of events 21 formula language 471
previewing documents 596
Web programming 79 Yesterday function
printing 550, 552
WebQuerySave events formula language 156, 472
properties of 510
table of events 21
refreshing 586, 587, 625
Web programming 79
refreshing on the Web 71
saving in Designer 552
Weekday function
formula language 156, 467
Z
scroll bars 624 Zone function
While function
searching 518, 519 formula language 156, 472
formula language 139, 468
selecting documents in 532 ZoomPreview command
White space
selecting documents to include formula language 632
in formula language 533
in 405, 511
Wide function
setting design for documents in 11,
formula language 469
511
Window
switching 598, 622
refreshing 586, 587
This information was developed for products and services offered in the USA. IBM may not offer the
products, services, or features discussed in this document in all countries. Consult your local IBM
representative for information on the products and services currently available in your area. Any reference
to an IBM product, program, or service is not intended to state or imply that only that IBM product,
program, or service may be used. Any functionally equivalent product, program, or service that does not
infringe any IBM intellectual property right may be used instead. However, it is the user's responsibility to
evaluate and verify the operation of any non-IBM product, program, or service.
IBM may have patents or pending patent applications covering subject matter described in this document.
The furnishing of this document does not give you any license to these patents. You can send license
inquiries, in writing, to:
IBM Director of Licensing
IBM Corporation
North Castle Drive
Armonk, NY 10504-1785
U.S.A.
For license inquiries regarding double-byte (DBCS) information, contact the IBM Intellectual Property
Department in your country/region or send inquiries, in writing, to:
IBM World Trade Asia Corporation Licensing
2-31 Roppongi 3-chome, Minato-ku
Tokyo 106, Japan
The following paragraph does not apply to the United Kingdom or any other country/region where such
provisions are inconsistent with local law:
INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS PUBLICATION "AS IS"
WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY, OR
FITNESS FOR A PARTICULAR PURPOSE.
Some states do not allow disclaimer of express or implied warranties in certain transactions; therefore,
this statement may not apply to you.
This information could include technical inaccuracies or typographical errors. Changes are periodically
made to the information herein; these changes will be incorporated in new editions of the publication. IBM
may make improvements and/or changes in the product(s) and/or the program(s) described in this
publication at any time without notice.
Any references in this information to non-IBM Web sites are provided for convenience only and do not in
any manner serve as an endorsement of those Web sites. The materials at those Web sites are not part
of the materials for this IBM product, and use of those Web sites is at your own risk.
IBM may use or distribute any of the information you supply in any way it believes appropriate without
incurring any obligation to you.
Licensees of this program who wish to have information about it for the purpose of enabling: (i) the
exchange of information between independently created programs and other programs (including this
one) and (ii) the mutual use of the information that has been exchanged, should contact:
Lotus Software
IBM Software Group
One Rogers Street
Cambridge, MA 02142
USA
Such information may be available, subject to appropriate terms and conditions, including in some cases
payment of a fee.
The licensed program described in this document and all licensed material available for it are provided by
IBM under terms of the IBM Customer Agreement, IBM International Program License Agreement, or by
any equivalent agreement between us.
Any performance data contained herein was determined in a controlled environment. Therefore, the
results obtained in other operating environments may vary significantly. Some measurements may have
been made on development-level systems, and there is no guarantee that these measurements will be
the same on generally available systems. Furthermore, some measurements may have been estimated
through extrapolation. Actual results may vary. Users of this document should verify the applicable data
for their specific environment.
Information concerning non-IBM products was obtained from the suppliers of those products, their
published announcements, or other publicly available sources. IBM has not tested those products and
cannot confirm the accuracy of performance, compatibility, or any other claims related to non-IBM
products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of
those products.
All statements regarding IBM's future direction or intent are subject to change or withdrawal without
notice, and represent goals and objectives only.
This information contains examples of data and reports used in daily business operations. To illustrate
them as completely as possible, the examples include the names of individuals, companies, brands, and
products. All of these names are fictitious and any similarity to the names and addresses used by an
actual business enterprise is entirely coincidental.
Trademarks
IBM, the IBM logo, AIX, DB2, Domino, Freelance, Freelance Graphics, iSeries, i5/OS, Lotus, Lotus Notes,
LotusScript, Notes, 1-2-3, OS/400, Quickplace, S/390, Sametime, SmartSuite, WebSphere, z/OS, and
zSeries are trademarks or registered trademarks of IBM Corporation in the United States, other countries,
or both.
Additional IBM copyright information can be found at: http://www.ibm.com/legal/copytrade.shtml
Java and all Java-based trademarks and logos are trademarks of Sun Microsystems, Inc. in the United
States, other countries, or both.
Microsoft, Windows, and the Windows logo are trademarks of Microsoft Corporation in the United States,
other countries, or both.
Intel and Pentium are trademarks of Intel Corporation in the United States, other countries, or both.
The Graphics Interchange Format(c) is the Copyright property of CompuServe Incorporated. GIF(sm) is a
Service Mark property of CompuServe Incorporated.
UNIX is a registered trademark of The Open Group in the United States and other countries.
Linux is a trademark of Linus Torvalds in the United States, other countries, or both.
Other company, product and service names may be trademarks or service marks of others.