Command to set mail file owner in calendar profile doc

Kindly let me know the code with which I can force “this mail belongs to” filed in calendar profile to take the orginal mail file owner.

urgent please…

Subject: Command to set mail file owner in calendar profile doc…

Urgent,…no one is gonna die.:wink:

Something similar:

'Set value of doc, db here

Set doc = db.GetProfileDocument("CalendarProfile")



	Call doc.ReplaceItemValue("Owner", "Bill Gates")

	Call doc.Save(True, True)

Subject: RE: Command to set mail file owner in calendar profile doc…

thanks…

instead of bill gates in the example…is there any field from which i can get the owner

Subject: RE: Command to set mail file owner in calendar profile doc…

Well you have the problem that the “this mail belongs to” field in calendar profile IS the mail file owner. There’s no other field, so if the Calendar Profile is wrong, you’ll would need to pick an arbitrary name from somewhere else.

I’d suggest, in most-likely order, choosing the name from:

  1. The first person in the Domino Directory address

    book “People” list who is defined having this database

    as his/her mailbox,

  2. The database’s title (if the title is the Common Name

    of a single Person found in the Domino Directory)

  3. The first entry in the database’s Access Control List which is

    both a Person, and which has Manager access, or the first

    Editor if no individual Manager is found.

  4. The name of the person defined as this database’s Owner in

    the server Catalog, if non-blank. (I’ve never seen a site

    where these were completed for mailboxes though, so don’t

    hold your breath on this one.)

It would be half a day’s work to write a Lotusscript class that implemented all of these options.