ProxyAuthor field missing

We have a database which registers new users via a variety of scripted procedures using the NotesRegistration class. Now I am trying to add the capability to set a newly registered user as a roaming user.

The roaming related properties of the NotesRegistration class are inadequate as they do not provide for setting a roaming replica server. So, I have turned to building the AdminP request document directly for the action “Update Roaming User State in Person Record”. This request processes without error, however the subsequent request for the action “Create Roaming User’s Replica Stubs”, which is created when the new user first logs on and accepts the roaming status, is missing the ProxyAuthor field which ultimately causes the entire process to break as this request is never processed.

Given that the AdminP request created by script processes fine, can anyone provide any clues as to why the subsequent generated request is faulty?

Many thanks,

Steve Tomaselli

Subject: Solution - ProxyAuthor field missing

Found my own answer. The original admin request document created via script had a critical field with an incorrect data type. The field ProxyOriginatingRequestUNID was being populated as plain text via doc.UniversalID. This creates a problem as the subsequent generated request must reference the original document via this field as a Response Reference List - basically a faux $REF field.

To create ProxyOriginatingRequestUNID as the correct data type, I simply create in memory a response document (which is never saved) and copy the item $REF to my original (“parent”) document with the new item name “ProxyOriginatingRequestUNID”. After that, all went well. Code snippet follows:

Sub CreateProxyUNID(refdoc As NotesDocument, refdb As NotesDatabase)

Dim tempdoc As NotesDocument

Set tempdoc = New NotesDocument(refdb)

Call tempdoc.MakeResponse(refdoc)

Dim refItem As NotesItem

Set refItem = tempdoc.GetFirstItem(“$REF”)

Call refdoc.CopyItem(refItem,“ProxyOriginatingRequestUNID”)

End Sub

Subject: RE: Solution - ProxyAuthor field missing

Now thats a really elegant way to construct a UNID. Nice one!

—* Bill

Subject: RE: Solution - ProxyAuthor field missing

Hi. This sounds brilliant! Any chances of posting the Update to Roaming user Adminp request script? I have a migration db which will automate the move, ACL and icon bits and pieces, it would be great to tag on enable roaming at the end.

Thanks in advance. John.