I am trying to read the Out Of Office status and message from other users in the organization from my c# program. We are running Exchange 2013 on premises.
This app is running as an Active Directory account (with it's own exchange mailbox), and I cannot use impersonation.
I have spent some time trying out the solutions to similar questions such as:
- Retrieve out of office Status using EWS 2.0 This one uses impersonation
- Read out of office from exchange server for other users I'm not using the Outlook Object Model
- How to get Out of Office for another mailbox again no impersonation for me
- http://gsexdev.blogspot.com/2011/11/using-mailtips-in-ews-to-get-oof-out-of.html I don't have reference to
ExchangeServiceBinding
, even though I'm usingMicrosoft.Exchange.WebServices.Data;
- http://blogs.msdn.com/b/devmsg/archive/2014/06/03/ews-how-to-retrieve-the-oof-out-of-facility-settings-message-using-ews-for-an-exchange-user.aspx This one takes as a paramater,
urlname
and I'm not sure where that url is coming from. This one seems the most promising though, any ideas where that comes from?
I'm trying to get something like:
public void checkOOF(string userEmail){
bool isOOF = checkstuff(userEmail);
string message;
if(isOOF)
message = getOOFMessage(userEmail);
}
Please help me understand, thank you.