I am trying to register 400 user using the NotesAdminstrationProcess Class and the RegisterNewUser method and I keep running into the same error when running the script. “access to data denied”. I tried stepping through the code in debugger but no results. Sometimes notes frustrates me with ridiculous generic error messages that really does not give much guidance to a resolution.
Any input will be appreciated. Here’s my code:
Dim session As New NotesSession
Dim dbase As NotesDatabase
Set dbase = session.CurrentDatabase
Dim regis As New NotesRegistration
Dim counter As Integer
Dim dt As Variant
For counter% = 1 To 400
dt = DateNumber(Year(Today)+1, Month(Today), Day(Today))
regis.Registrationserver = “SERVER1/INDEPENDENT”
regis.CreateMailDb = False
regis.CertifierIDFile = “C:\Notes\Data\cert.id”
regis.IDType = ID_HIERARCHICAL
regis.MinPasswordLength = 5
regis.IsNorthAmerican = True
regis.RegistrationLog = “certlog.nsf”
regis.UPdateAddressBook = True
regis.StoreIDInAddressBook = True
Call regis.RegisterNewUser(“user” + CStr(counter%),_ 'last name
“user” + CStr(counter%) + “.id”,_ ’ file to be created
“CN=SERVER1/O=INDEPENDENT”,_
“test”,_ 'first name
“”,_
“puncrifa”,_
“”,_
“”,_
“mail/user” + CStr(counter%) + “.nsf”,_
“”,_
“LOTUSNOTES”)
Next
End Sub