Search This Blog

Tuesday, June 24, 2014

Modifying the Mail File Owner Field

Back in the day, which would be the Lotus Notes/Domino R5 days, if you needed to change the mail file owner field in a database, be it mail-in or person, it was a simple process. Open the mail file, click on Preferences – Mail – Basics, select a name from the Domino Directory, and save the Preference.
Apparently, to “prevent issues caused by the name in the Mail File Owner field not existing as a valid hierarchical name in the Domino Directory,” this behavior was changed in Release 6. The field was protected and usually required a change to the design of the mail file to allow this field to be edited.
That is a tiresome change.
If you have a mail file, or mail-in database, where you want to change the Owner field, it is as simple as creating a button and mailing it to the affected user (bad idea). I prefer using the same technique, but instead of waiting for the user to do something (click a button, in this case), open the mail file, create a button, and click it for the user.
Open the mail file.
Create a new messsage
In a blank line of the new message, click Create – Hotspot – Button. Give the button a name, in this case “ClickMe.”
Now, add some code to the button:
@SetProfileField(“CalendarProfile”;”Owner”;”<hierarchical name of user>”)
Example: @SetProfileField(“CalendarProfile”;”Owner”;”CN=Gregg Eldred/O=Acme”)
Click the green check mark, to save the code.
The button is now on a blank memo, created in the mail file of the person who has an issue with the Owner field. And, as you created the button, the field value is perfect.
Click the button.
To confirm that your code worked, open Preferences – Mail – Basics. You should see something like this:
There, problem solved and the user didn’t have to do a thing (that’s called a “win” in my book).

No comments:

Post a Comment