Technotes & goodies
R5 Database Manager
Database Manager is an impressive example of the use of C API from LotusScript. Andrew Luder has built this cool application taking as a starting point great existing samples. Although the application has R5 in its name, I tried it out in ND6 and it was working fine; for any productive purpose it should be tested more carefully.
Download: R5 Database Manager
Here is a short description provided by Andrew:
The R5 Database Manager has been created to manage Notes databases in small to enterprise-wide domains using LotusScript and C API to set most ACL, Database, Replication and Advanced Replication settings on R5 databases. It processes a selected database and all its replicas (can also create and delete replicas on other servers) in a domain if selected. It's also possible to add all replicas of a selected database to your desktop.
Its code has been built/expanded from the various Lotus Scipt/C API contributions over the years in the forums by many authors such as Normunds Kalnberzins and Rod Whitely as well as the dbdesign stuff by Damien Katz (and expanded dbdesign by Josh Jore).
Basic Functions are:
* Set ACL,Database, Replication and Advanced Replication settings of single database.
* Set consistent ACL,Database, Replication and Advanced Replication settings on all replicas of a database (selected servers can be excluded if required).
* Create replicas with consistent ACL,Database, Replication and Advanced Replication settings.
* Delete replicas except source (database profiled).
* Replica Server/Username to -Any Server-, -Any Server- to -Any Server- and Replica Server/Username to <Servername> advanced replication notes will be created if they don't exist when the Create/Update action is used.
* Enable/disable any of the ACL,Database, Replication and Advanced Replication settings from processing.
* Keep a log of actions performed.
* Add all database icon replicas to your workspace desktop (selected servers can be excluded if required).
* Use System Profile to specify whether advanced options are shown and to specify a default list of excluded servers.
* Only one ACL setting can be performed at a time.
* Hasn't been tested with R4 or R6 Notes clients (will have different nnotes.dll).
* This was developed using the Lotus C API 5.0.7 Reference. Therefore, would recommend using at least a 5.0.7 Notes client or higher with this database.
* A hidden text field called TempFields is used to store all the item names of a database when selected on creation. If the number of fields stored breaks the 15000 character mark, you will receive a warning message everytime the Database Profile is saved that this limit has been exceeded for this field, will be saved, but can't be displayed in a view. Just an annoyance.....
* Settings with a red title (advanced options) can only be set programatically and not through the Notes Client. Unless you need to use them leave alone.
* The Hide Design option only disables the Notes client options from looking at a selected database's design elements. It does not strip any code.
* Get NotesPeek to look at changes made to advanced replication notes.
* Build on/expand the script libraries for your own requirements.
* Check out www.ls2capi.com