Hi,
Hoping someone out there can help me with this.
I'm provisioning users with Quick Connect from a HR database to ActiveRoles Server, this part works great.
What I want to do now, is write the info about the newly provisioned user to a SQL database via a stored procedure, this is an internal telephone directory used on the intranet.
I've attempted to do this via a Workflow in ASR that calls a Powershell script. As below:
The script activity is as follows:
The user is created in ASR but not in the SQL database, errors in the EDM logs are generated via an error trap in the powershell script:
Workflow activity has reported an alert. Workflow name: Notify on User Provision from ESR Workflow GUID: 5a9aaae2-2fa3-4d2a-9bff-6a2bf3e8a495 Workflow instance GUID: 70a8dbfa-6869-4a40-a751-8fb70011eee0 Activity name: powerShellActivity1 Activity type: Quest.ActiveRolesServer.Workflow.Activities.PowerShellActivity.PowerShellActivity Script Module: Write User Provision Info To Staff Directory Details: At line: 8 char:6. Trapped Error: Cannot index into a null array..Exception.Message; More: System.Management.Automation.RuntimeException; Position At line:14 char:25 + $strFirstName = $srcObj[ <<<< "givenName"]
AND:
Execution of workflow instance failed. Workflow name: Notify on User Provision from ESR Workflow GUID: 5a9aaae2-2fa3-4d2a-9bff-6a2bf3e8a495 Workflow instance GUID: 70a8dbfa-6869-4a40-a751-8fb70011eee0 Operation ID: 1-45152 Operation GUID: 8eebe370-088b-42ab-8843-ef748a47da47 Operation: Create Object
Object name: Bilbo Baggins
Object parent container: domain.x.uk/x/x/x
Object type: user
Object GUID:
Initiator: DOMAIN\activerolesserver
Details:
At line: 8 char:6. Trapped Error: Cannot index into a null array..Exception.Message; More: System.Management.Automation.RuntimeException;
Position
At line:14 char:25
+ $strFirstName = $srcObj[ <<<< "givenName"]