Hi everyone!

I have some doubts about the execution of Powershell commands for
Exchange using the Active Directory driver. The scneario is the

The Exchange mailserver has many MDBs so one thing that I have to do is
to get the number of mailboxes of the MDB, that I set into a Global
Configuration Variable, to know if the MDB hasn't reached the max limit
of mailboxes. If the count is less than the max limit, the mailbox is
created in the MDB, if it is greater than the limit I choose other MDB.
The first question is if it's possible update the value of a GCV because
if the result is greater, I want to set the Global Configuration
Variable with the new MDB and the second question is how to save the
result returned by the powershell command?

To get the number of mailboxes I test the following commands into the
PowerShell Console:

$MDB = \"MAILBOX DATABASE 0531187302\"

In this case the result is: 3

So I plan add destination attribute value *PSExecute *with that
commands, but I don't know how to save the result. In the AD driver the
*$mdb* variable will be the GCV.

The other thing that I have to do is to verify if the Mailbox Address
doesn't exist yet, and the question it's the same, how to get the result
that return the Powershell command(s) during the execution of the AD
Driver rule?

The documentation says that if you set/add the PSexecute attribute with
the commands, the AD driver understand that and execute them. But I'm
not sure if only works with commands that don't return a result, like
-*enable-Mailbox*- command.

Any Ideas to do that?

Thank you!

ktorres00's Profile: https://forums.netiq.com/member.php?userid=2355
View this thread: https://forums.netiq.com/showthread.php?t=48945