0 votes

Trying to run a business rule to update the user account and email address after the user got married.

If the operation succeeded AND the user has an Exchange mailbox then Modify the user: set Email to '%userPrincipalName%' Modify mailbox settings for the user: modify E-Mail Addresses (add 'SMTP:%userPrincipalName%')

by (480 points)
0

Hello Derek,

Sorry for the confusion, but we are not sure we understand what exactly the issue is. Per your description the Business Rule should work just fine. Could you, please, describe the desired behavior in all the possible details with live examples? If you face any errors, please, post here or send us (support[at]adaxes.com) screenshots.

0

We changed the last name of a user The rule haa still not run on the account. The email, display name, etc. are still the old name

0

Hello Derek,

The rule haa still not run on the account.

Could you, please, make sure that the Business Rule is effective for the user account you are updating? For information on how to check that, have a look at the following help article: https://www.adaxes.com/help/?ManageBusinessRules.ViewBusinessRulesEffectiveForADObjects.html.

The email, display name, etc. are still the old name

According to your description, the Business Rule should only update email addresses of the user and nothing else. Could you, please, specify what exactly needs to be changed? Also, please, post here or send us (support[at]adaxes.com) a screenshot of the Business Rule.

0

Could you, please, make sure that the Business Rule is effective for the user account you are updating?

According to your description, the Business Rule should only update email addresses of the user and nothing else. Could you, please, specify what exactly needs to be changed?
image.png

Yes only email - sorry this is new name: image.png Still old name image.png

1 Answer

0 votes
by (289k points)

Hello Derek,

Do we understand correctly that the new email (based on the new last name) is added to the list of user email addresses, but the Email property of the user remains as is? If that is correct, most probably, the issue occurs because the new email address is automatically overwritten by Exchange based on email address policies. To achieve the desired, you need to make sure that the new address is set as primary and the automatic email update is disabled. Finally, the settings of the Modify Exchange properties action in the Business Rule should be as follows: image.png

0

When i look at the email there is nto a new email with her new name.

image.png

0

Hello Derek,

According to your description, you are using value reference %userPrincipalName% to specify the new email address. Could you, please, make sure that the UPN Logon Name (LDAP name userPrincipalName) property gets changed when you update the last name of the user?

What about the Modify Exchange properties action? Did you try to configure it according to the screenshot in our previous post?

0

Ok i made the email changes according to the link and i added code to make other property changes and changed the last name of a test account and still nothing

image.png

0

Hello Derek,

The thing is that value references resolve before performing actions in a Business Rule, Custom Command or Scheduled Task. It means that if you update a property in one action and then try to use the property value reference in the next action (e.g. like you are doing with the UPN Logon Name property) the value in the second action will still be old. To achieve the desired behavior, you need to remove the first 4 actions from the Business Rule and configure the Property Pattern effective for the user to update user properties when related properties are updated. Alternatively, you need to use %firstname%.%lastname%@ahfproducts.com in the last two actions instead of the %userPrincipalName% value reference.

For information on how to check effective Property Patterns for a user, have a look at the following help article: https://www.adaxes.com/help/?ManagePropertyPatterns.ViewPropertyPatternsEffectiveForADObjects.html. To update the patterns to modify property values upon related property updates:

  1. Launch Adaxes Administration Console.
  2. In the Console Tree, expand your service node.
  3. Navigate to Configuration\Property Patterns and select the pattern you need.
  4. In the Result Pane on the right, right-click the property you need (e.g. Full Name).
  5. In the context menu, click Edit. image.png
  6. Select on creating and editing objects below the Generate default value field. image.png
  7. Click OK
  8. Repeat steps 4-6 for all the required properties.
  9. Save the changes.
0

This worked!!!! Thank You.

Related questions

0 votes
1 answer

Hi team, I have a follow up to this question https://www.adaxes.com/questions/14234/business-after-adding-members-powershell-script-executed Let me explain my setup A rule- ... area% failed due to the following exception: $($_.Exception.Message)", "Error") }

asked Feb 13 by wintec01 (1.5k points)
0 votes
1 answer

Hi, I have a business rule setup to perform actions after user creation. First action is to run a powershell script which works and it sets a required AD attribute ( ... new user sits in the original OU and does not move Am i missing something here?

asked Feb 6 by Lewis (40 points)
0 votes
1 answer

Hi team, I need to update users extensionAttribute6 after adding or removing them from a specific group. This is my setup: Group is updated based on rule set within Adaxes ... would like to update users after they were added or removed from this group. Thanks!

asked Sep 25, 2023 by wintec01 (1.5k points)
0 votes
1 answer

I need a way of triggering a business rule based on the user (and not the group) being added or removed from a group. The reason I would like this triggered on the user is so ... prefer not to do that. I am checking to see if there is another way to do this.

asked May 16, 2023 by mark.it.admin (2.3k points)
0 votes
1 answer

I have created a Business Rule (call it BR1) that occurs After adding or removing a member from a group . For testing purposes, it currently runs a PowerShell script ... the Business Rule I created. Is this expected behavior? Or am I doing something wrong?

asked Apr 12, 2023 by alex.vanderwoude (60 points)
3,545 questions
3,236 answers
8,229 comments
547,809 users