Search DominoPower's 10,675 Lotus-related article archive 
Home
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.
Twitter Feed Click here for the Twitter feed.
DEVELOPING AGENTS
How to automatically build groups based on ACL roles
By Tom Lowery

There is a dilemma that faces all Notes a and Domino developers at some point in their careers. Has this ever happened to you? You're building a large workflow application with lots of roles. Those roles can be filled by individuals and public NAB (Name and Address Book) groups alike. Now you want your application to send mail to everyone in a given role. What do you do? Do you now go to your local friendly system administrator and ask her to add still more groups to the public NAB to match your roles? What happens if you have twenty such applications? Your public NAB group list will soon look something like this, or worse:

HR-Directory-[ViewSalary]
HR-Directory-[ChangeSalary]
HR-Directory-[ViewHomeAddress]
AP-Invoices-[ViewVendorAddresses]
AP-Invoices-[PayInvoices]

This clutters the NAB group list and can be a pain to administer.

The problem lies in the way the Domino object model is constructed. There's no easy way for a LotusScript program to determine, for each role, which people and groups are members of that role. Going the other way is simple. The NotesACLEntry.roles property can be used to determine which roles are enabled for an ACL (Access Control List) entry.

A similar situation exists with documents and folders. In R4, there is no easy way to get a list of all the folders a document resides in. That situation is corrected in R5. However, it looks like the ACL role situation will not be changing anytime soon. While anything could happen before R5 goes gold, there appears to be no new functionality to help with role lookups as of Beta 2.

Creating group documents
If you're like me, you may have been tempted to create group documents, locally within the application database. These would match the roles you have defined. This approach is straightforward enough. Simply create a form called Group with two fields, ListName and Members. Both are text fields. Make sure that the Members field has the Allow Multi-values property turned on. You can see an example of this in Figure A.

FIGURE A


Try creating a simple form containing group name and members. Roll over picture for a larger image.

Then, create a view called Groups with a single sorted column, GroupName, as shown in Figure B.

FIGURE B


Create a simple view with one column called GroupName. Roll over picture for a larger image.

From there, you can use the following formula to pull the group members and send email to them:

@DbLookup (""; @DbName; "Groups"; roleName; "Members")

This approach keeps the public NAB clean. It also makes your system administrator happy since she doesn't have to keep adding new groups. The drawback, of course, is added work on your part. Every time you add someone to the ACL and give him a role, you must remember to also update the local group document that corresponds to that role.


1  ·  2  ·  Next »
Other articles you might like
Home > Lotus Technologies > Access Control (7 articles)
   Forcing immediate indexes to actually update immediately
   Enabling and disabling the single login setting in Notes 6
   Coding Domino server tasks in C: beyond Windows
Get Weekly Email Updates
Subscribe to our regular weekly email newsletter. It's packed with tips, reviews, deep analysis, and the latest news.
 
Recent DominoPower Articles
What to look for in a Domino-based document management solution
Understanding Domino.doc end-of-life options
When the debugger won't debug hidden code that isn't hidden
What to do if the LotusScript debugger won't single-step over code
Top 10 ways to launch and build a Lotus consulting practice (with a little help from the Beatles)
Troubleshooting an OpenSuse Notes install
Incident report: denial of service attack against ConnectedPhotographer.com
Latest Lotus Headlines
SnTT - Enabling ALL the bells and whistles!
Tivoli Data protection causes Domino to crash
Fun when running DB2 CLP scripts
Introducing Flippr, the easy way to admin Quickr
DXL and fake security
Using search forms in IBM Workplace Collaborative Learning 2.7
Schmidt, Freed, and Gering on the OVF Toolkit
>> Read all the news
More from the ZATZ journals
Computing Unplugged: Eight steps to successful and reliable home backups
David Gewirtz Online: CNN commentary and analysis
OutlookPower: Can Outlook run when it's not running (and other mysteries)?
-- Advertisement --

AUTOMATE LOTUS NOTES USER ID MANAGEMENT
ID Manager 4.5 from HELP Software provides a new level of automaton for managing Lotus Notes IDs. ID Manager lets Lotus Notes administrators get out of the business of creating and managing user IDs. Use our ROI calculator to see how quickly ID Manager will pay for itself.

Learn more about HELP Software products
-- Advertisement --

Want The Top Lotus Experts By Your Side Without Paying Hefty Consulting Fees? Look No Further.
Like having a team of consultants by your side -- ones who have all the answers and never make mistakes -- THE VIEW gives you immediate access to field-tested instruction, guidance, and best practices from the brightest Lotus professionals around.

Join your peers who realize their Lotus technology is too important to let people from blogs and forums tell them how they should implement it, run it, and use it. THE VIEW is where only the world's top Lotus experts provide validated support to you on a weekly basis to ensure you work more efficiently, get more out of your Lotus technology, and stay clear of costly mistakes.

Check out the new instruction, tips, and best practices added to THE VIEW this week.

ZATZ Home  ·  News  ·  Back Issues  ·  Credits/Trademarks ·  Link To Us
Copyright © 1998-2009, ZATZ Publishing. All rights reserved worldwide.
Editor's Login