Email:   
Home
In This Issue
Email a Friend
EasyPrint
News details Click here for the RSS feed's XML code. This is not a browser URL.
Articles-only Click here for the RSS feed's XML code. This is not a browser URL.
Doing more in Lotuscript with Notes.Net class libraries (continued)

Now let's look at some examples.

NotesFTP
NotesFTP is implemented as a single Lotuscript class library. I can't say more about the value of using this than is offered by the author, Paul Ray:

If you've ever implemented FTP functionality in your applications using LotusScript, chances are it was done by making a call to the Shell function and running an FTP executable against a batch (.BAT) file containing FTP commands. Having passwords stored on the file system, even temporarily, can make an Administrator cringe, and "shelling" out to the command line is something many seasoned Developers do not want a part of.

NotesFTP provides a mechanism that overcomes both of these hurdles. For one, usernames and passwords can be kept in the confines of a Notes/Domino LotusScript module (e.g., agent), so they are secure. Secondly, the FTP calls are made "in process" rather than by launching a separate executable to do so, making the code more robust and efficient.

NotesFTP is also easy to use. Since it is implemented as a LotusScript Class, you are sheltered from making calls directly to the Win32 Internet API, and thus do not need to be concerned with the details surrounding calls to DLLs. Instead, the details are all encapsulated in an object that you manipulate.

As he says, it works by making calls to the Microsoft Internet Functions API (application programming interface), which is in WinInet.DLL. That file comes with Internet Explorer, so that means that if you want to use it in server-based applications, like I did, you need to have Internet Explorer installed on the server. Once I did that, it all worked for me just as documented, and it was real easy to write code that worked first time. In fact, the only issue I have with the library is that the documentation omits to describe the method GetFile. A quick check of the script library itself showed that GetFile and PutFile have the same parameters. I can easily live with this.

NotesTemplate
This class has just two properties, but it could be a real time-saver to many administrators. With the standard NotesDatabase class, the properties DesignTemplateName and Templatename give access to the template name that a database inherits from, and for templates, the name the template is. But these are read-only properties. Daniel Alvers' class enables you to update these values. I have used this as part of a mail upgrade project to enable me to modify the template names on mail databases without having to go and do each one by hand. Daniel wrote it to help a project of standardizing template names at his company. It's one of those things that you hardly ever need, but when you do need it, it will save you so much time and effort.

NotesUserActivity
Another class by Daniel Alvers gives access to the User Activity table in a Notes database--the same data that you see when you hit the User Detail button on the "i" tab of the database properties box. I've used this information to generate activity reports for a database, so that we can see that the database is being used, how often, and by whom. This class presents the data in the same order as in the dialog box, last entry first and in descending date order. This enables you to see the most current data first, indeed finding out who last accessed the database, and when, is real easy. Just as with looking at the dialog box, you need to filter out the servers from the real users. I'd do a NotesView.GetAllEntriesByKey using the activity entry name as key on the directory's $Servers view. If you get no returned value, it means it's not a server.




[ Prev | Next ]

ZATZ Home  ·  News  ·  Back Issues  ·  Credits/Trademarks ·  Link To Us
-- 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 --

DEPARTMENT CALENDAR - MANAGE AND SHARE A COMMON CALENDAR WITH YOUR TEAMS
Are you responsible for improving your organization's Group Calendaring tool? Have you been tasked to find a true group calendar tool with Itinerary, Time-Off, Sign In/Out and Bulletins/Events module that seamlessly integrates with Domino calendaring?

If so, Logic Springs Technologies will make answering these questions a whole lot easier!

Learn how by visiting us at www.departmentcalendar.com

Copyright © 1998-2008, ZATZ Publishing. All rights reserved worldwide.
Editor's Login