|
|
|
|
|
|
|
|
|
|
PROGRAMMING POWER
The new NotesOutline class in Notes 5.0
By Tony Patton
Last month, we discussed the many enhancements to LotusScript that are part of Notes and Domino Release 5.0. One of the items mentioned was the new outline feature and its corresponding NotesOutline class. This month we'll get much more in-depth, and you'll learn how to script with outlines.
Notes Release 5.0 has a distinctive Internet flavor to it. Developing applications for both WebWeb browsers and Notes clients was a nightmare with previous versions of Notes, but Release 5.0 has made the process much simpler by eliminating the need to develop for both. The Notes client now supports all elements supported by a typical Web browser. These elements include frames, HTML, Java applets, and more.
In addition, the new outline feature in Notes 5.0 adds the ability to assemble a site map. The site map gives you an overview of what is in an application -- and that application can include more than one database. The outline can also include links to Domino databases, views, documents, and Web sitesWeb sites (i.e., URLs). The Notes Release 5.0 development environment makes it easy to create and set up an outline, as shown in Figure A, and the NotesOutline and NotesOutlineEntry LotusScript classes are provided to work with an outline in script.
FIGURE A
You can easily create a Notes outline. Click picture for a larger image.
Note: The first beta copy of Notes 5.0 was used in this article. Future updates to the 5.0 code may change aspects of the NotesOutline and NotesOutlineEntry classes.
A simple scripting example Let's take a look at a short routine that makes use of the new outline features.
Sub Initialize
Dim session As New NotesSession
Dim db As NotesDatabase
Set db = session.CurrentDatabase
Dim outline As New NotesOutline(db)
Dim entry As NotesOutlineEntry
Set entry = outline.GetFirst
While Not (entry Is Nothing)
Print entry.TitleText
Set entry = outline.GetNext(entry)
Wend
End Sub
|
Here's an explanation of what that all means:
- First, we declare a new NotesOutline object. The parameter is the name of the database for the outline.
- Next, declare a new NotesOutlineEntry object. This will be used to access individual elements in the outline.
- The GetFirst method of the NotesOutline class is used to get a handle on the first element in the outline.
- A while loop is used to scroll through all elements in an outline.
- The TitleText property of the NotesEntry class returns the title text assigned to an entry.
- The GetNext method is used to retrieve the next element from the outline, the current entry is passed as a reference point.
[ Next ]
|
|
|
|
|
|
-- Advertisement --
PistolSTAR: the de facto standard for Lotus authentication
PistolStar's Password Power integrates with Microsoft Active Directory to enable single sign-on to Lotus applications and automatic recovery of the Notes ID password via self-service reset of the Active Directory password.
- A single set of credentials to remember - one set of password policies to manage.
- Cost-effective plug-ins integrate smoothly with your environment.
- Proven, ground-breaking technology deployed to millions of users.
Learn more. |
-- Advertisement --
SECURTRAC - MONITOR AND CONTROL YOUR DOMINO ENVIRONMENT
When it comes to your business, how do you ensure compliance with SOX, HIPAA or other industry driven regulations? Use SecurTrac to monitor and audit the life cycle of all objects in your Domino environment.
- Database Monitor
- Mail Monitor
- Domino Directory Monitor
- Notes.ini File Monitor
- Intrusion Detection Monitor
Click here for details and a free evaluation copy. |
|
|
|
|
|
|
|
|