Finding Users Who Have “Out Of Office” Enabled In Exchange 2010…

It might come in handy if you know how to get a list of users who have out of office message turned on. Exchange 2010 shell gives you that ability now.

You can even change the message, set the audience (internal or external), turn it off etc with the shell.

To get a list of users who have out of office scheduled, run the following command.

Get-Mailbox | Get-MailboxAutoReplyConfiguration | Where-Object { $_.AutoReplyState –eq “scheduled” }

The above command gives you much more than you need, including the actual message, start time, end time etc.

If you are only interested in the list of users, run

Get-Mailbox | Get-MailboxAutoReplyConfiguration | Where-Object { $_.AutoReplyState –eq “scheduled” } | fl identity

Find USers with oof scheduled

If you want to get the settings for a particular user (for example Rajith), run

Get-MailboxAutoReplyConfiguration –identity rajith

You can also change the out of office settings for a particular user with the Set-MailboxAutoReplyConfiguration cmdlet.

For example, to turn off the out of office for the user account “Rajith”, run

Set-MailboxAutoReplyConfiguration –identity “Rajith” –AutoreplyState disabled

Disable autoreply

Similarly, if you want to extend the out of office message for a user (change the end time), run

Set-MailboxAutoReplyConfiguration –identity “Rajith” –EndTime 01/12/2009 17:00:00

You can change the actual out of office message (internal and external) by running

Set-MailboxAutoReplyConfiguration –identity “Rajith” –InternalMessage “I won’t be around today guys” –ExternalMessage “I am out of the office today”

Do note that this cmdlets will only work in Exchange 2010 Shell!

8 Responses to “Finding Users Who Have “Out Of Office” Enabled In Exchange 2010…”

  1. Anonymous November 19, 2009 at 12:20 am #

    Very cool.. really enjoy your blogs, thanks Liam

    [Reply]

  2. Rajith Jose Enchiparambil November 19, 2009 at 8:45 am #

    Thanks Liam.

    [Reply]

  3. sh-eli December 19, 2009 at 9:00 am #

    Cool post

    http://elishlomo.spaces.live.com/default.aspx

    [Reply]

  4. Rajith Jose Enchiparambil December 19, 2009 at 12:08 pm #

    Thanks Sh-eli.

    [Reply]

  5. Anonymous July 23, 2010 at 1:26 am #

    Hi does anyone know how to get all the mailboxes with OOF enabled, disable it, then re-enable it for those same users?

    The reason is I want to run it at midnight each night as a scheduled task to reset the 'sent to' list. I have a lot of requests to sent OOF once per day per sender, instead of once per OOF period.

    I need some help piping this together

    Get this and store in variable
    Get-Mailbox | Get-MailboxAutoReplyConfiguration | Where-Object { $_.AutoReplyState –eq “scheduled”

    Then do this
    Set-MailboxAutoReplyConfiguration –AutoreplyState disabled

    Then do this
    Set-MailboxAutoReplyConfiguration –AutoreplyState enabled

    [Reply]

  6. Anonymous July 23, 2010 at 1:30 am #

    Thanks for posting the article.
    I think it should be 'Enabled' instead of 'Scheduled'

    Where-Object { $_.AutoReplyState –eq “Enabled” }

    [Reply]

  7. Anonymous March 21, 2011 at 7:57 am #

    Thanks for the post it really helped

    [Reply]

  8. Rajith Jose Enchiparambil March 21, 2011 at 9:34 am #

    Thanks Anonymous.

    [Reply]

Leave a Reply:

Gravatar Image