Ask a questionAsk a question
 

Answernew-mailbox cmdlet and log

  • Wednesday, November 04, 2009 10:35 AMmig.en_ Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Hi.

    I have written a script to make new mailboxes. This script is very simple, is just like this:

    import-csv newusers.csv | new-mailbox

    The command new-mailbox has some parameters that I haven't written above.

    It works fine.

    But if some of these identities already exists in Active Directory, then some red words appear in the powershell window, warning of this error.

    I'd like to keep a log about all errors found by new-mailbox command. And if new users is successfully created, then I would also like to have it in this log.

    Do you know how to keep a log when using new-mailbox cmdlet?

    Thanks, bye,

    Mig. En.

Answers

All Replies