0 votes

I would like to add the following logic into a Powershell script that will be triggered on 'After Create User'.

  • Read the value of the 'title' property of the user just created
  • Search Adaxes for a Custom Command that has the same name as the value of 'title' (textual equivalence)
  • Invoke the Custom Command found

I will create Custom Commands to match every possible value of 'title' and each will take a single parameter of 'True' or 'False'.

Could you assist with how to script this please?

Many thanks.

by (310 points)

1 Answer

0 votes
by (227k points)

Hello Bernie,

Have a look at the following script from our repository: https://www.adaxes.com/script-repository/execute-custom-command-with-name-specified-in-user-property-s574.htm. If the Custom Command to be executed has parameters that should be specified upon execution, have a look at the following SDK article for an example: https://adaxes.com/sdk/?IAdmTop6.html. Should you have issues updating the script to meet your needs, please, provide us with all the possible details on the parameters and their values to be set for command execution, and we will help you.

Related questions

0 votes
1 answer

Hi Is it possible to get a business rule which calls a custom command powershell script to wait for the script to complete before continuing? Thanks Matt

asked Apr 27, 2017 by chappers77 (1.2k points)
0 votes
1 answer

Hi, I followed this example: https://www.adaxes.com/sdk/IAdmTop6.html, but because the Custom Command is disabled, I get the following error message: System.Management.Automation ... if I enable the Custom Command. I am using Adaxes 2018.2 Best Regards Martin

asked Feb 19, 2020 by Martin (50 points)
0 votes
1 answer

Hello, Is it possible to execute a custom command after creating a user, with the intention to prompt the end user for more information? For example we have a User ... would then prompt for a 'Country' to be specified from a param dropdown list. Thanks

asked Mar 10 by bavery (250 points)
0 votes
1 answer

Is there a way to get the name of the user who approved a request and supply that to a step inside of a custom command? For example, HR submits a status change for an employee. ... and pass it as a param in a custom command that is called in one of the steps?

asked May 12, 2021 by davfount90 (20 points)
0 votes
1 answer

When creating custom commands you have to select the object type. What is the object type for a Business Unit? It doesn't seem to be OU or Container as I can not select ... execute my script against. I've been searching the site and can not find this detail.

asked Jul 5, 2021 by ComputerHabit (790 points)
2,797 questions
2,530 answers
6,594 comments
57,504 users