Format a Users Name

Table of contents:

Format a User s Name

Several properties are associated the NotesName class that enable you to return different versions of a user's Lotus Notes name. Several of the more common properties include the Common, Abbreviated and Canonical formats.

How It Works

Simply assign a value to an object and reference one of the property formats.

ImplementationExample 1

This first example displays the user's name in the common format (see Figure 13.16).

Dim s As NotesSession
Dim person As NotesName
Set s = New NotesSession
Set person = New NotesName(s.UserName)
Msgbox "This is the COMMON format: " & person.Common

Figure 13.16. Example of the Common user name format

 

ImplementationExample 2

This second example illustrates the user's name in the Abbreviated format (see Figure 13.17). This format as well as the Common format can be used to send emails.

Dim s As NotesSession
Dim person As NotesName
Set s = New NotesSession
Set person = New NotesName(s.UserName)
Msgbox "This is the ABBREVIATED format: " & person.Abbreviated

Figure 13.17. Example of the Abbreviated user name format

 

ImplementationExample 3

The third example shows the user's name in the Canonical format (see Figure 13.18).

Dim s As NotesSession
Dim person As NotesName
Set s = New NotesSession
Set person = New NotesName(s.UserName)
Msgbox "This is the CANONICAL format: " & person.Canonical

Figure 13.18. Example of the Canonical user name format


An Introduction to the Lotus Domino Tool Suite

Getting Started with Designer

Navigating the Domino Designer Workspace

Domino Design Elements

An Introduction to Formula Language

An Introduction to LotusScript

Fundamentals of a Notes Application

Calendar Applications

Collaborative Applications

Reference Library Applications

Workflow Applications

Web Applications

Design Enhancements Using LotusScript

Design Enhancements Using Formula Language

View Enhancements

Sample Agents

Miscellaneous Enhancements and Tips for Domino Databases

Data Management

Security

Application Deployment and Maintenance

Troubleshooting

Appendix A. Online Project Files and Sample Applications

Appendix B. IBM® Lotus® Notes® and Domino®Whats Next?



Lotus Notes Developer's Toolbox(c) Tips for Rapid and Successful Deployment
Lotus Notes Developers Toolbox: Tips for Rapid and Successful Deployment
ISBN: 0132214482
EAN: 2147483647
Year: N/A
Pages: 293
Authors: Mark Elliott

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