<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>JOAO LIVIO - Microsoft Online Services</title>
	<atom:link href="http://exchws.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://exchws.wordpress.com</link>
	<description>Microsoft Online Services Blog</description>
	<lastBuildDate>Wed, 15 May 2013 12:08:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='exchws.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://1.gravatar.com/blavatar/d0eae3aadccf2e45fcfe611f4ea21f68?s=96&#038;d=http%3A%2F%2Fs2.wp.com%2Fi%2Fbuttonw-com.png</url>
		<title>JOAO LIVIO - Microsoft Online Services</title>
		<link>http://exchws.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://exchws.wordpress.com/osd.xml" title="JOAO LIVIO - Microsoft Online Services" />
	<atom:link rel='hub' href='http://exchws.wordpress.com/?pushpress=hub'/>
		<item>
		<title>2012 in review</title>
		<link>http://exchws.wordpress.com/2013/01/28/2012-in-review/</link>
		<comments>http://exchws.wordpress.com/2013/01/28/2012-in-review/#comments</comments>
		<pubDate>Mon, 28 Jan 2013 19:35:12 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://exchws.wordpress.com/?p=463</guid>
		<description><![CDATA[The WordPress.com stats helper monkeys prepared a 2012 annual report for this blog. Here&#8217;s an excerpt: 600 people reached the top of Mt. Everest in 2012. This blog got about 11,000 views in 2012. If every person who reached the top of Mt. Everest viewed this blog, it would have taken 18 years to get [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=463&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>The WordPress.com stats helper monkeys prepared a 2012 annual report for this blog.</p>
<p>	<a href="http://exchws.wordpress.com/2012/annual-report/"><img src="http://www.wordpress.com/wp-content/mu-plugins/annual-reports/img/2012-emailteaser.png" width="100%" alt="" /></a></p>
<p>Here&#8217;s an excerpt:</p>
</p>
<blockquote><p>600 people reached the top of Mt. Everest in 2012.  This blog got about <strong>11,000</strong> views in 2012. If every person who reached the top of Mt. Everest viewed this blog, it would have taken 18 years to get that many views.</p></blockquote>
<p><a href="http://exchws.wordpress.com/2012/annual-report/">Click here to see the complete report.</a></p>
<br />Filed under: <a href='http://exchws.wordpress.com/category/uncategorized/'>Uncategorized</a>  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/463/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/463/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=463&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2013/01/28/2012-in-review/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>

		<media:content url="http://www.wordpress.com/wp-content/mu-plugins/annual-reports/img/2012-emailteaser.png" medium="image" />
	</item>
		<item>
		<title>EWS API 1.2 Released</title>
		<link>http://exchws.wordpress.com/2012/06/25/ews-api-1-2-released-2/</link>
		<comments>http://exchws.wordpress.com/2012/06/25/ews-api-1-2-released-2/#comments</comments>
		<pubDate>Mon, 25 Jun 2012 08:50:20 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Exchange Web Services]]></category>
		<category><![CDATA[Exchange Online]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=460</guid>
		<description><![CDATA[Good news, the Exchange Web Services Managed API 1.2.1 was released and it’s available for download The EWS Managed API 1.2 introduces the following important changes that might affect your client applications: Microsoft Exchange Server 2010 Service Pack 2 (SP2) is now the targeted version The following new functionality is exposed: Getting password expiration date [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=460&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<h5></h5>
<p><strong></strong></p>
<p><strong>Good news</strong>, the Exchange Web Services Managed API 1.2.1 was released and it’s available for download</p>
<p><font size="2"><strong>The EWS Managed API 1.2</strong> introduces the following important changes that might affect your client applications: </font></p>
<p><font size="2">Microsoft Exchange Server 2010 Service Pack 2 (SP2) is now the targeted version</font></p>
<ol>
<li><font size="2">The following new functionality is exposed: </font></li>
<li><font size="2">Getting password expiration date </font></li>
<li><font size="2">Updates to the contact type </font></li>
<li><font size="2">Store entry identifiers returned on items </font></li>
<li><font size="2">Asynchronous notifications </font></li>
<li><font size="2">DateTime object precision values </font></li>
</ol>
<h5>Documentation</h5>
<p><a href="http://msdn.microsoft.com/en-us/library/dd633709(v=exchg.80).aspx"><font size="2">http://msdn.microsoft.com/en-us/library/dd633709(v=exchg.80).aspx</font></a></p>
<h5>Download</h5>
<p><a href="http://www.microsoft.com/en-us/download/details.aspx?id=28952"><font size="2">http://www.microsoft.com/en-us/download/details.aspx?id=28952</font></a></p>
<p><font size="2"></font></p>
<br />Filed under: <a href='http://exchws.wordpress.com/category/exchange-web-services/'>Exchange Web Services</a> Tagged: <a href='http://exchws.wordpress.com/tag/exchange-online/'>Exchange Online</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/460/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/460/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=460&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2012/06/25/ews-api-1-2-released-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>
	</item>
		<item>
		<title>Run Exchange Online PowerShell Commands with C#</title>
		<link>http://exchws.wordpress.com/2011/12/22/run-exchange-online-powershell-commands-with-c/</link>
		<comments>http://exchws.wordpress.com/2011/12/22/run-exchange-online-powershell-commands-with-c/#comments</comments>
		<pubDate>Thu, 22 Dec 2011 13:33:32 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[PowerShell Management]]></category>
		<category><![CDATA[PowerShell Managment for Exchange]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=452</guid>
		<description><![CDATA[Instead of running PowerShell Commands within the Console, in some scenarios, it’s important to automate this procedure and give users the ability to manage Exchange Online. In this sample I’m creating a mailbox. I’m explaining all steps in code. I Suggest to Run this sample first in a Console Application Leave a message if you [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=452&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Instead of running PowerShell Commands within the Console, in some scenarios, it’s important to automate this procedure and give users the ability to manage Exchange Online. In this sample I’m creating a mailbox. I’m explaining all steps in code.</p>
<p>I Suggest to Run this sample first in a Console Application</p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image19.png"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:inline;border-top:0;border-right:0;padding-top:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb18.png?w=55&#038;h=55" width="55" height="55" /></a></p>
<p>Leave a message if you have any issues</p>
<div class="code"><font face="Consolas"><font size="2"><font color="#0000ff">using</font><font color="#808080">&#160;</font><font color="#000000">System.Collections.Generic</font><font color="#0000ff">;</font></font></font><font color="#808080">     <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">using</font><font color="#808080">&#160;</font><font color="#000000">System.Management.Automation.Runspaces</font><font color="#0000ff">;</font></font></font><font color="#808080">     <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">using</font><font color="#808080">&#160;</font><font color="#000000">System.Management.Automation</font><font color="#0000ff">;</font> </font></font></div>
<p><font color="#006400" size="2" face="Consolas"></font></p>
<p><font face="Consolas"><font size="2"><font color="#006400">// Set credentials to make a remote connection to Outlook Live          <br /></font><font color="#0000ff">string</font><font color="#808080">&#160;</font><font color="#000000">userName</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080"> <a href="mailto:admin@contoso.com">admin@contoso.com</a></font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">string</font><font color="#808080">&#160;</font><font color="#000000">password</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080"> &quot;password&quot;</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#000000">SecureString</font><font color="#808080">&#160;</font><font color="#000000">secureString</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">SecureString()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">foreach</font><font color="#808080">&#160;</font><font color="#000000">(</font><font color="#0000ff">char</font><font color="#808080">&#160;</font><font color="#000000">c</font><font color="#808080">&#160;</font><font color="#0000ff">in</font><font color="#808080">&#160;</font><font color="#000000">password)</font><font color="#808080">&#160;</font><font color="#000000">secureString.AppendChar(c)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">secureString.MakeReadOnly()</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#000000">PSCredential</font><font color="#808080">&#160;</font><font color="#000000">credential</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">PSCredential(userName,</font><font color="#808080">&#160;</font><font color="#000000">secureString)</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// Set the connection Info          <br /></font><font color="#000000">WSManConnectionInfo</font><font color="#808080">&#160;</font><font color="#000000">connectionInfo</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">WSManConnectionInfo(</font><font color="#0000ff">new</font></font></font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">Uri(</font><font color="#808080">&quot;<a href="https://ps.outlook.com/powershell/&#038;quot" rel="nofollow">https://ps.outlook.com/powershell/&#038;quot</a>;</font><font color="#000000">),</font></font></font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160;&#160;&#160;&#160;&#160; &quot;<a href="http://schemas.microsoft.com/powershell/Microsoft.Exchange&#038;quot" rel="nofollow">http://schemas.microsoft.com/powershell/Microsoft.Exchange&#038;quot</a>;</font></font><font face="Consolas"><font size="2"><font color="#000000">,</font><font color="#808080">&#160;</font><font color="#000000">credential)</font><font color="#808080">&#160;</font></font></font></p>
<div class="code"><font face="Consolas"><font size="2"><font color="#808080">&#160;&#160;&#160;&#160; </font><font color="#000000">{</font><font color="#808080">&#160;</font><font color="#000000">AuthenticationMechanism</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">AuthenticationMechanism.Basic</font><font color="#808080">&#160;</font><font color="#000000">}</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font color="#006400" size="2" face="Consolas">// create a runspace on a remote path      <br />// the returned instance must be of type RemoteRunspace       <br /></font><font color="#808080">     <br /></font><font face="Consolas"><font size="2"><font color="#000000">Runspace</font><font color="#808080">&#160;</font><font color="#000000">runspace</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">RunspaceFactory.CreateRunspace()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">PowerShell</font><font color="#808080">&#160;</font><font color="#000000">powershell</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">PowerShell.Create()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">PSCommand</font><font color="#808080">&#160;</font><font color="#000000">command</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">PSCommand()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddCommand(</font><font color="#808080">&quot;New-PSSession&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddParameter(</font><font color="#808080">&quot;ConfigurationName&quot;</font><font color="#000000">,</font><font color="#808080"> &quot;Microsoft.Exchange&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddParameter(</font><font color="#808080">&quot;ConnectionUri&quot;</font><font color="#000000">,</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">Uri(</font><font color="#808080">&quot;<a href="https://ps.outlook.com/powershell/&#038;quot" rel="nofollow">https://ps.outlook.com/powershell/&#038;quot</a>;</font><font color="#000000">))</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddParameter(</font><font color="#808080">&quot;Credential&quot;</font><font color="#000000">,</font><font color="#808080">&#160;</font><font color="#000000">credential)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddParameter(</font><font color="#808080">&quot;Authentication&quot;</font><font color="#000000">,</font><font color="#808080"> &quot;Basic&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">//-AllowRedirection          <br /></font><font color="#000000">powershell.Commands</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">command</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// open the remote runspace          <br /></font><font color="#000000">runspace.Open()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#006400">// associate the runspace with powershell          <br /></font><font color="#000000">powershell.Runspace</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">runspace</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#006400">// invoke the powershell to obtain the results          <br /></font><font color="#2b91af">Collection</font><font color="#000000">&lt;PSSession&gt;</font><font color="#808080">&#160;</font><font color="#000000">result</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">powershell.Invoke&lt;PSSession&gt;()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">foreach</font><font color="#808080">&#160;</font><font color="#000000">(ErrorRecord</font><font color="#808080">&#160;</font><font color="#000000">current</font><font color="#808080">&#160;</font><font color="#0000ff">in</font><font color="#808080">&#160;</font><font color="#000000">powershell.Streams.Error)</font></font></font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#2b91af">Console</font><font color="#000000">.WriteLine(</font><font color="#2b91af">String</font><font color="#000000">.Format(</font><font color="#808080">&quot;The following Error happen when opening the remote Runspace: {0} | InnerException: {1}&quot;</font><font color="#000000">,</font><font color="#808080">&#160;</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#808080">&#160;&#160;&#160;&#160; </font><font color="#000000">current.</font><font color="#2b91af">Exception</font><font color="#000000">,</font><font color="#808080">&#160;</font><font color="#000000">current.</font><font color="#2b91af">Exception</font><font color="#000000">.InnerException))</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#2b91af">Console</font><font color="#000000">.ReadLine()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">if</font><font color="#808080">&#160;</font><font color="#000000">(result.Count</font><font color="#808080">&#160;</font><font color="#000000">!</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#800000">1</font><font color="#000000">)</font></font></font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#0000ff">throw</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#2b91af">Exception</font><font color="#000000">(</font><font color="#808080">&quot;Unexpected number of Remote Runspace connections returned.&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#006400">// Set the runspace as a local variable on the runspace          <br /></font><font color="#000000">powershell</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">PowerShell.Create()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">PSCommand()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddCommand(</font><font color="#808080">&quot;Set-Variable&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddParameter(</font><font color="#808080">&quot;Name&quot;</font><font color="#000000">,</font><font color="#808080"> &quot;ra&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddParameter(</font><font color="#808080">&quot;Value&quot;</font><font color="#000000">,</font><font color="#808080">&#160;</font><font color="#000000">result[</font><font color="#800000">0</font><font color="#000000">])</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell.Commands</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">command</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell.Runspace</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">runspace</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell.Invoke()</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#000000">powershell</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">PowerShell.Create()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">PSCommand()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#0000ff">const</font><font color="#808080">&#160;</font><font color="#0000ff">string</font><font color="#808080">&#160;</font><font color="#000000">CreateMailBoxScript</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080"> &quot;new-mailbox -Name:&#8217;{0}&#8217; -Password:(ConvertTo-SecureString {1}&#160; -AsPlainText -Force) -WindowsLiveID:{2} -FirstName:{3} -LastName:{4} -DisplayName:&#8217;{5}&#8217;&quot;</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">command.AddScript(</font><font color="#0000ff">string</font><font color="#000000">.Format(CreateMailBoxScript,</font><font color="#808080"> &quot;Joao&quot;</font><font color="#000000">,</font><font color="#808080"> &quot;password&quot;</font><font color="#000000">,</font><font color="#808080"> <a href="mailto:jlivio@contoso.com">jlivio@contoso.com</a></font><font color="#000000">,</font><font color="#808080"> &quot;Joao&quot;</font><font color="#000000">,</font><font color="#808080"> &quot;Livio&quot;</font><font color="#000000">,</font><font color="#808080"> &quot;Joao Livio&quot;</font><font color="#000000">))</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell.Commands</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">command</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell.Runspace</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">runspace</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell.Invoke()</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// dispose the runspace and enable garbage collection          <br /></font><font color="#000000">runspace.Dispose()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">runspace</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">null;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#006400">// Finally dispose the powershell and set all variables to null to free          <br />// up any resources.           <br /></font><font color="#000000">powershell.Dispose()</font><font color="#0000ff">;</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">powershell</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">null;</font> </font></font></div>
<br />Filed under: <a href='http://exchws.wordpress.com/category/powershell-management/'>PowerShell Management</a> Tagged: <a href='http://exchws.wordpress.com/tag/powershell-managment-for-exchange/'>PowerShell Managment for Exchange</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/452/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/452/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=452&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/22/run-exchange-online-powershell-commands-with-c/feed/</wfw:commentRss>
		<slash:comments>17</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb18.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>
	</item>
		<item>
		<title>How to get Exchange Online Folders</title>
		<link>http://exchws.wordpress.com/2011/12/20/how-to-get-exchange-online-folders/</link>
		<comments>http://exchws.wordpress.com/2011/12/20/how-to-get-exchange-online-folders/#comments</comments>
		<pubDate>Tue, 20 Dec 2011 14:04:15 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Exchange Web Services]]></category>
		<category><![CDATA[EWS Attachment's]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=446</guid>
		<description><![CDATA[You can get all folders based in a criteria, this is useful because it can be queried by a SearchFilter. In this case I’m only get Folders that have at least 1 message because operator is SearchFilter.IsGreaterThan &#160; SearchFilter searchFilter = new SearchFilter.IsGreaterThan (FolderSchema.TotalCount, 0); &#160; Unlike messages, in folders, you can use Deep Transversal&#8217;s, [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=446&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>You can get all folders based in a criteria, this is useful because it can be queried by a SearchFilter. In this case I’m only get Folders that have at least 1 message because operator is <font color="#000000">SearchFilter.IsGreaterThan</font> </p>
<p>&#160;</p>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">SearchFilter</font><font color="#808080"> </font><font color="#000000">searchFilter</font><font color="#808080"> </font><font color="#0000ff">=</font><font color="#808080"> </font><font color="#0000ff">new</font><font color="#808080"> </font><font color="#000000">SearchFilter.IsGreaterThan</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">(FolderSchema.TotalCount,</font><font color="#808080"> </font><font color="#800000">0</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font></div>
<div class="code"><font color="#0000ff" size="2" face="Consolas"></font></div>
<div class="code">&#160;</div>
<div class="code">Unlike messages, in folders, you can use Deep Transversal&#8217;s, this means that you can get all Sub Folders on the fly.</div>
<div class="code">&#160;</div>
<div class="code">&#160;</div>
<p><font face="Consolas"><font size="2"><font color="#000000">view.Traversal</font><font color="#808080"> </font><font color="#0000ff">=</font><font color="#808080"> </font><font color="#000000">FolderTraversal.Deep</font><font color="#0000ff">;</font></font></font></p>
<p><font color="#0000ff" size="2" face="Consolas">&#160;</font></p>
<p>As always you have to use an Object type of ExchangeService(), see the <a href="http://exchws.wordpress.com/exchange-on-line/exchange-server-binding/">GetBinding() Method</a></p>
<p><strong>&#160;</strong></p>
<p><strong>Main Procedure</strong></p>
<p><strong>&#160;</strong></p>
<div class="code"><font face="Consolas"><font size="2"><font color="#006400">// Create a view with a page size of 10 or number you want.          <br /></font><font color="#000000">FolderView</font><font color="#808080">&#160;</font><font color="#000000">view</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">FolderView(</font><font color="#800000">10</font><font color="#000000">)</font></font></font><font color="#808080">      <br /></font><font color="#000000" size="2" face="Consolas">{</font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">PropertySet</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">PropertySet</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">&#160;&#160;&#160;&#160; (BasePropertySet.IdOnly)</font><font color="#808080">&#160;</font><font color="#000000">{</font><font color="#808080">&#160;</font><font color="#000000">FolderSchema.DisplayName</font><font color="#808080">&#160;</font><font color="#000000">}</font></font></font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#000000">}</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font color="#006400" size="2" face="Consolas">// Identify the properties to return in the results set.</font><font color="#808080">      <br /></font><font face="Consolas"><font size="2"><font color="#006400">// Return only folders that contain items.          <br /></font><font color="#000000">SearchFilter</font><font color="#808080">&#160;</font><font color="#000000">searchFilter</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">SearchFilter.IsGreaterThan</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">&#160; (FolderSchema.TotalCount,</font><font color="#808080">&#160;</font><font color="#800000">0</font><font color="#000000">)</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// Unlike FindItem searches, folder searches can be deep traversals.          <br /></font><font color="#000000">view.Traversal</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">FolderTraversal.Deep</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// Send the request to search the mailbox and get the results.          <br /></font><font color="#000000">FindFoldersResults</font><font color="#808080">&#160;</font><font color="#000000">findFolderResults</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">service.FindFolders</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">&#160; (WellKnownFolderName.Root,</font><font color="#808080">&#160;</font><font color="#000000">searchFilter,</font><font color="#808080">&#160;</font><font color="#000000">view)</font><font color="#0000ff">;</font></font></font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// Process each item.          <br /></font><font color="#0000ff">foreach</font><font color="#808080">&#160;</font><font color="#000000">(Folder</font><font color="#808080">&#160;</font><font color="#000000">myFolder</font><font color="#808080">&#160;</font><font color="#0000ff">in</font><font color="#808080">&#160;</font><font color="#000000">findFolderResults.Folders)</font></font></font><font color="#808080">      <br /></font><font color="#000000" size="2" face="Consolas">{</font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160; <font face="Consolas"><font size="2"><font color="#006400">// Go get myFolder.Id, MyFolder.DisplayName etc…</font></font></font>         <br /></font></font><font color="#000000" size="2" face="Consolas">}</font><font color="#808080">      </p>
<p></font><font face="Consolas"><font size="2"><font color="#006400">// Determine whether there are more folders to return.          <br /></font><font color="#0000ff">if</font><font color="#808080">&#160;</font><font color="#000000">(findFolderResults.MoreAvailable)</font></font></font><font color="#808080">      <br /></font><font color="#000000" size="2" face="Consolas">{</font><font color="#808080">      <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#006400">// Make recursive calls with offsets set for the FolderView </font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#006400">&#160;&#160;&#160; // to get the remaining folders in the result set for Paging.          <br /></font><font color="#000000">}</font> </font></font></div>
<br />Filed under: <a href='http://exchws.wordpress.com/category/exchange-web-services/'>Exchange Web Services</a> Tagged: <a href='http://exchws.wordpress.com/tag/ews-attachments/'>EWS Attachment's</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/446/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/446/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=446&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/20/how-to-get-exchange-online-folders/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>
	</item>
		<item>
		<title>EWS User Impersonation, advantages, why?</title>
		<link>http://exchws.wordpress.com/2011/12/15/ews-user-impersonation-advantages-why/</link>
		<comments>http://exchws.wordpress.com/2011/12/15/ews-user-impersonation-advantages-why/#comments</comments>
		<pubDate>Thu, 15 Dec 2011 13:30:20 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Exchange Web Services]]></category>
		<category><![CDATA[EWS Impersonation]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=408</guid>
		<description><![CDATA[&#160; First off all I respect all points of views, this post is intend only to expose my opinion. ACTIVATE IMPERSONATION FOR ADMINISTRATOR First go to Roles &#38; Management and then Discovery Management, Second, add a function ApplicationImpersonation, then add the Administrator User Name IMPERSONATION IN DETAIL When you connect to exchange online, you must [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=408&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>&#160;</p>
<p>First off all I respect all points of views, this post is intend only to expose my opinion.</p>
<p><strong>ACTIVATE IMPERSONATION FOR ADMINISTRATOR</strong></p>
<p>First go to <strong>Roles &amp; Management</strong> and then <strong>Discovery Management</strong>, Second, add a function <strong>ApplicationImpersonation</strong>, then add the <strong>Administrator User Name</strong></p>
<table border="0" cellspacing="0" cellpadding="2" width="400">
<tbody>
<tr>
<td valign="top" width="200"><a href="http://exchws.files.wordpress.com/2011/12/image12.png"><img style="background-image:none;padding-left:0;padding-right:0;display:block;float:none;margin-left:auto;margin-right:auto;padding-top:0;border-width:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb12.png?w=342&#038;h=242" width="342" height="242" /></a></td>
<td valign="top" width="200"><a href="http://exchws.files.wordpress.com/2011/12/image13.png"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:block;float:none;margin-left:auto;border-top:0;margin-right:auto;border-right:0;padding-top:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb13.png?w=216&#038;h=328" width="216" height="328" /></a></td>
</tr>
</tbody>
</table>
<p><strong>IMPERSONATION IN DETAIL</strong></p>
<p>When you connect to exchange online, you must communicate with an Exchange Web Service within a mailbox user and a password, but if you are logged with a non Administrator user you may not have Full control over the Service. This may be true when you have Hybrid Systems, and in some procedures like <a href="http://exchws.wordpress.com/2011/12/08/reply-and-forward-with-full-information/">CreateReply()</a> or <a href="http://exchws.wordpress.com/2011/12/08/reply-and-forward-with-full-information/">CreateForward()</a> you may experience Access Denied Exceptions.</p>
<p>Another point is if you use the Administrator Credentials and Impersonate another Mailbox you don’t have to know that users credentials and this may be an advantage in all ways.</p>
<p>How can we do this?</p>
<p>Just use your service binding method, or get it <a href="http://exchws.wordpress.com/exchange-on-line/exchange-server-binding/">here</a> and impersonate the service like this</p>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">service.ImpersonatedUserId</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#0000ff">new</font><font color="#808080">&#160;</font><font color="#000000">ImpersonatedUserId</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#000000">&#160;&#160; (ConnectingIdType.SmtpAddress,</font><font color="#808080">&#160;</font></font></font></div>
<div class="code"><font face="Consolas"><font size="2"><font color="#808080">&#160;&#160;&#160;&#160;&#160; &quot;You non Admin MailBox&quot;</font><font color="#000000">)</font><font color="#0000ff">;</font> </font></font></div>
<br />Filed under: <a href='http://exchws.wordpress.com/category/exchange-web-services/'>Exchange Web Services</a> Tagged: <a href='http://exchws.wordpress.com/tag/ews-impersonation/'>EWS Impersonation</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/408/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/408/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=408&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/15/ews-user-impersonation-advantages-why/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb12.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb13.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>
	</item>
		<item>
		<title>EWS Autodiscover Diagnostic Utility &#8211; Beta 3</title>
		<link>http://exchws.wordpress.com/2011/12/14/ews-autodiscover-diagnostic-utility-beta-3/</link>
		<comments>http://exchws.wordpress.com/2011/12/14/ews-autodiscover-diagnostic-utility-beta-3/#comments</comments>
		<pubDate>Wed, 14 Dec 2011 22:33:44 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Downloads and Utilities]]></category>
		<category><![CDATA[EWS Autodiscover Diagnostic]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=389</guid>
		<description><![CDATA[GET IT NOW Added Smart management for Connection Problems Microsoft Remote Connectivity Analyzer Link Microsoft SharePoint 2010 Suggested Connection Now Detect if Mailbox Plan is Disable Minor code changes Filed under: Downloads and Utilities Tagged: EWS Autodiscover Diagnostic<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=389&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><a title="http://exchws.wordpress.com/ews-autodiscover-diagnostic-utility/" href="http://exchws.wordpress.com/ews-autodiscover-diagnostic-utility/"><strong>GET IT NOW</strong></a></p>
<p><strong>Added</strong></p>
<ul>
<li>Smart management for Connection Problems </li>
<li>Microsoft Remote Connectivity Analyzer Link </li>
<li>Microsoft SharePoint 2010 Suggested Connection </li>
<li>Now Detect if Mailbox Plan is Disable </li>
<li>Minor code changes </li>
</ul>
<br />Filed under: <a href='http://exchws.wordpress.com/category/downloads-and-utilities/'>Downloads and Utilities</a> Tagged: <a href='http://exchws.wordpress.com/tag/ews-autodiscover-diagnostic/'>EWS Autodiscover Diagnostic</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/389/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/389/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=389&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/14/ews-autodiscover-diagnostic-utility-beta-3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>
	</item>
		<item>
		<title>Activate User Impersonation in Office 365 for Exchange Online</title>
		<link>http://exchws.wordpress.com/2011/12/13/activate-user-impersonation-in-office-365-for-exchange-online/</link>
		<comments>http://exchws.wordpress.com/2011/12/13/activate-user-impersonation-in-office-365-for-exchange-online/#comments</comments>
		<pubDate>Tue, 13 Dec 2011 16:36:02 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Office 365]]></category>
		<category><![CDATA[Office 365 Configuration]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=367</guid>
		<description><![CDATA[Having problems impersonate accounts in Exchange Online?, OK, follow this steps 1 – Manage your Organization 2 – Go Roles &#38; Auditing and Double click Discover Management 3 – Add the ApplicationImpersonation Role and then the User that can Impersonate Filed under: Office 365 Tagged: Office 365 Configuration<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=367&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Having problems impersonate accounts in Exchange Online?, OK, follow this steps</p>
<p>1 – Manage your Organization</p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image3.png"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:inline;border-top:0;border-right:0;padding-top:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb3.png?w=192&#038;h=79" width="192" height="79" /></a></p>
<p>2 – Go <strong>Roles &amp; Auditing</strong> and Double click <strong>Discover Management</strong></p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image4.png"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:inline;border-top:0;border-right:0;padding-top:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb4.png?w=482&#038;h=301" width="482" height="301" /></a></p>
<p>3 – Add the <strong>ApplicationImpersonation</strong> Role and then the User that can Impersonate</p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image5.png"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:inline;border-top:0;border-right:0;padding-top:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb5.png?w=423&#038;h=433" width="423" height="433" /></a></p>
<br />Filed under: <a href='http://exchws.wordpress.com/category/office-365/'>Office 365</a> Tagged: <a href='http://exchws.wordpress.com/tag/office-365-configuration/'>Office 365 Configuration</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/367/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/367/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=367&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/13/activate-user-impersonation-in-office-365-for-exchange-online/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb3.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb4.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb5.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>
	</item>
		<item>
		<title>What is the Service Binding in the Exchange Web Services Managed API</title>
		<link>http://exchws.wordpress.com/2011/12/13/what-is-the-service-binding-in-the-exchange-web-services-managed-api/</link>
		<comments>http://exchws.wordpress.com/2011/12/13/what-is-the-service-binding-in-the-exchange-web-services-managed-api/#comments</comments>
		<pubDate>Tue, 13 Dec 2011 15:27:49 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Exchange Web Services]]></category>
		<category><![CDATA[EWS]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=357</guid>
		<description><![CDATA[The Microsoft Exchange Web Services Managed API have 2 main classes, the FOLDER Class and the ITEM Class. All these 2 need a ServiceObject in order to communicate with a Exchange Web service. Service Binding use the Autodiscover Object in order to get a Exchange Web Service endpoint URL, something like this https://SERVER.outlook.com/EWS/Exchange.asmx. The Folder [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=357&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>The <strong>Microsoft Exchange Web Services Managed API</strong> have 2 main classes, the <strong>FOLDER</strong> Class and the <strong>ITEM</strong> Class. All these 2 need a <strong>ServiceObject</strong> in order to communicate with a Exchange Web service.</p>
<p>Service Binding use the Autodiscover Object in order to get a Exchange Web Service endpoint URL, something like this <a href="https://SERVER.outlook.com/EWS/Exchange.asmx">https://</a><a href="https://server.outlook.com/EWS/Exchange.asmx">SERVER</a><a href="https://server.outlook.com/EWS/Exchange.asmx">.outlook.com/EWS/Exchange.asmx</a></a>.</p>
<p><strong>The Folder Class</strong></p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image.png"><img style="background-image:none;padding-left:0;padding-right:0;display:inline;padding-top:0;border-width:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb.png?w=589&#038;h=167" width="589" height="167" /></a></p>
<p><strong>The Item Class</strong></p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image1.png"><img style="background-image:none;padding-left:0;padding-right:0;display:inline;padding-top:0;border-width:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb1.png?w=590&#038;h=278" width="590" height="278" /></a></p>
<p>You can see at the TOP of the hierarchy <strong>SERVICEOBJECT </strong>that is a type of ExchangeService() Object</p>
<p>So what next? let’s see in more detail, what Outlook do if you add a Microsoft Exchange Account?</p>
<p><a href="http://exchws.files.wordpress.com/2011/12/image2.png"><img style="background-image:none;border-bottom:0;border-left:0;padding-left:0;padding-right:0;display:inline;border-top:0;border-right:0;padding-top:0;" title="image" border="0" alt="image" src="http://exchws.files.wordpress.com/2011/12/image_thumb2.png?w=457&#038;h=318" width="457" height="318" /></a></p>
<p>In this case <strong>Outlook</strong> will try to resolve thru <strong>Autodiscover</strong> the domain in the E-mail Address field, and get the Endpoint for the Exchange Web Service, if the credentials are OK, all user configurations and Mail will be attached to Outlook</p>
<p>Service Binding do the same thing, the only difference is that you will assign properties values to a <strong>ExchangeService()</strong>, and assign user information&#8217;s like the <strong>Endpoint URL</strong> in order to you can use All Objects in the <strong>FOLDER</strong> and <strong>ITEM</strong> Class</p>
<p>Let’s see the <strong>Method </strong><a href="http://exchws.wordpress.com/exchange-on-line/exchange-server-binding/">here</a><strong></strong></p>
<p>Enjoy EWS!</p>
<br />Filed under: <a href='http://exchws.wordpress.com/category/exchange-web-services/'>Exchange Web Services</a> Tagged: <a href='http://exchws.wordpress.com/tag/ews/'>EWS</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/357/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/357/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=357&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/13/what-is-the-service-binding-in-the-exchange-web-services-managed-api/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb1.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>

		<media:content url="http://exchws.files.wordpress.com/2011/12/image_thumb2.png" medium="image">
			<media:title type="html">image</media:title>
		</media:content>
	</item>
		<item>
		<title>Delete a Message or a List of Messages</title>
		<link>http://exchws.wordpress.com/2011/12/13/delete-a-message-or-a-list-of-messages/</link>
		<comments>http://exchws.wordpress.com/2011/12/13/delete-a-message-or-a-list-of-messages/#comments</comments>
		<pubDate>Tue, 13 Dec 2011 15:10:06 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Exchange Web Services]]></category>
		<category><![CDATA[EWS Messages]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=348</guid>
		<description><![CDATA[You will need the GetBind() method in order to use this code This method will delete a message based in a Message Unique ID and move it to deleted folders, you can change it for your needs /// &#60;summary&#62; /// Deletes the message. /// &#60;/summary&#62; /// &#60;param name=&#34;messId&#34;&#62;The mess id.&#60;/param&#62; public&#160;static&#160;bool&#160;DeleteMessageByID(string&#160;messId) { &#160;&#160;&#160; Item&#160;mess&#160;=&#160;Item.Bind(GetBinding(),&#160;messId); &#160;&#160;&#160; [&#8230;]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=348&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p><strong>You will need the </strong><a href="http://exchws.wordpress.com/exchange-server-binding/" target="_blank"><strong>GetBind()</strong></a><strong> method in order to use this code</strong></p>
<p>This method will delete a message based in a Message Unique ID and move it to deleted folders, you can change it for your needs</p>
<div class="code"><font face="Consolas"><font size="2"><font color="#006400">/// &lt;summary&gt;         <br />/// Deletes the message.          <br />/// &lt;/summary&gt;          <br />/// &lt;param name=&quot;messId&quot;&gt;The mess id.&lt;/param&gt;          <br /></font><font color="#0000ff">public</font><font color="#808080">&#160;</font><font color="#0000ff">static</font><font color="#808080">&#160;</font><font color="#0000ff">bool</font><font color="#808080">&#160;</font><font color="#000000">DeleteMessageByID(</font><font color="#0000ff">string</font><font color="#808080">&#160;</font><font color="#000000">messId)</font></font></font><font color="#808080">     <br /></font><font color="#000000" size="2" face="Consolas">{</font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">Item</font><font color="#808080">&#160;</font><font color="#000000">mess</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">Item.Bind(GetBinding(),</font><font color="#808080">&#160;</font><font color="#000000">messId)</font><font color="#0000ff">;</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">EmailMessage</font><font color="#808080">&#160;</font><font color="#000000">message</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#808080">&#160;</font><font color="#000000">mess</font><font color="#808080">&#160;</font><font color="#0000ff">as</font><font color="#808080">&#160;</font><font color="#000000">EmailMessage</font><font color="#0000ff">;</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#0000ff">if</font><font color="#808080">&#160;</font><font color="#000000">(message</font><font color="#808080">&#160;</font><font color="#0000ff">==</font><font color="#808080">&#160;</font><font color="#0000ff">null</font><font color="#000000">)</font><font color="#808080">&#160;</font><font color="#0000ff">return</font><font color="#808080">&#160;</font><font color="#0000ff">false;</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">message.Delete(DeleteMode.MoveToDeletedItems)</font><font color="#0000ff">;</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#0000ff">return</font><font color="#808080">&#160;</font><font color="#0000ff">true;</font></font></font><font color="#808080">     <br /></font><font color="#000000" size="2" face="Consolas">}</font><font color="#808080">     <br /></font></div>
<div class="code"><font color="#808080">&#160;</font></div>
<p>This method will delete a List of messages based in a Message Unique ID that you pass in the List&lt;String&gt; and move it to deleted folders, you can change it for your needs<font color="#808080"></font>
<div class="code"></div>
<p>   <font face="Consolas"><font size="2"><font color="#006400">/// &lt;summary&gt;         <br />/// Deletes the message list.          <br />/// &lt;/summary&gt;          <br />/// &lt;param name=&quot;messId&quot;&gt;The mess id.&lt;/param&gt;          <br /></font><font color="#0000ff">public</font><font color="#808080">&#160;</font><font color="#0000ff">static</font><font color="#808080">&#160;</font><font color="#0000ff">bool</font><font color="#808080">&#160;</font><font color="#000000">DeleteListOfMessagesByID</font><font color="#000000">&lt;</font><font color="#0000ff">string</font><font color="#000000">&gt;</font><font color="#808080">&#160;</font><font color="#000000">messId)</font></font></font><font color="#808080">     <br /></font><font color="#000000" size="2" face="Consolas">{</font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#0000ff">foreach</font><font color="#808080">&#160;</font><font color="#000000">(EmailMessage</font><font color="#808080">&#160;</font><font color="#000000">message</font><font color="#808080">&#160;</font><font color="#0000ff">in</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160;&#160;&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">messId.Select(messIdList</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#000000">&gt;</font><font color="#808080">&#160;</font><font color="#000000">Item.Bind(GetBinding(),</font></font></font><font face="Consolas"><font size="2"><font color="#808080">&#160; <br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; </font><font color="#000000">messIdList)).Select(mess</font><font color="#808080">&#160;</font><font color="#0000ff">=</font><font color="#000000">&gt;</font><font color="#808080">&#160;</font><font color="#000000">mess</font><font color="#808080">&#160;</font><font color="#0000ff">as</font><font color="#808080">&#160;</font><font color="#000000">EmailMessage))</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font color="#000000" size="2" face="Consolas">{</font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160;&#160;&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#0000ff">if</font><font color="#808080">&#160;</font><font color="#000000">(message</font><font color="#808080">&#160;</font><font color="#0000ff">==</font><font color="#808080">&#160;</font><font color="#0000ff">null</font><font color="#000000">)</font><font color="#808080">&#160;</font><font color="#0000ff">return</font><font color="#808080">&#160;</font><font color="#0000ff">false;</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160;&#160;&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#000000">message.Delete(DeleteMode.MoveToDeletedItems)</font><font color="#0000ff">;</font></font></font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font color="#000000" size="2" face="Consolas">}</font><font color="#808080">     <br /><font size="2" face="Consolas">&#160;&#160;&#160; </font></font><font face="Consolas"><font size="2"><font color="#0000ff">return</font><font color="#808080">&#160;</font><font color="#0000ff">true;</font></font></font><font color="#808080">     <br /></font><font face="Consolas"><font size="2"><font color="#000000">}</font> </font></font></p>
<p>&#160;</p>
<p>I you think this helped you, please take 10 second’s and respond to the question in the side bar, Thanks.</p>
<br />Filed under: <a href='http://exchws.wordpress.com/category/exchange-web-services/'>Exchange Web Services</a> Tagged: <a href='http://exchws.wordpress.com/tag/ews-messages/'>EWS Messages</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/348/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/348/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=348&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/13/delete-a-message-or-a-list-of-messages/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>
	</item>
		<item>
		<title>Where is the Exchange Web Services Managed API 1.2 SDK?</title>
		<link>http://exchws.wordpress.com/2011/12/13/where-is-the-exchange-web-services-managed-api-1-2-sdk/</link>
		<comments>http://exchws.wordpress.com/2011/12/13/where-is-the-exchange-web-services-managed-api-1-2-sdk/#comments</comments>
		<pubDate>Tue, 13 Dec 2011 14:48:26 +0000</pubDate>
		<dc:creator>Joao Tito Livio</dc:creator>
				<category><![CDATA[Exchange Web Services]]></category>
		<category><![CDATA[EWS How do i?]]></category>

		<guid isPermaLink="false">https://exchws.wordpress.com/?p=346</guid>
		<description><![CDATA[Exchange Web Services Managed API 1.2 SDK is available in http://msdn.microsoft.com/en-us/library/dd633710(EXCHG.80).aspx but at the time of this post isn’t available for download yet. Filed under: Exchange Web Services Tagged: EWS How do i?<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=346&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></description>
				<content:encoded><![CDATA[<p>Exchange Web Services Managed API 1.2 SDK is available in <a href="http://msdn.microsoft.com/en-us/library/dd633710(EXCHG.80).aspx">http://msdn.microsoft.com/en-us/library/dd633710(EXCHG.80).aspx</a> but at the time of this post isn’t available for download yet.</p>
<br />Filed under: <a href='http://exchws.wordpress.com/category/exchange-web-services/'>Exchange Web Services</a> Tagged: <a href='http://exchws.wordpress.com/tag/ews-how-do-i/'>EWS How do i?</a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/exchws.wordpress.com/346/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/exchws.wordpress.com/346/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=exchws.wordpress.com&#038;blog=24478012&#038;post=346&#038;subd=exchws&#038;ref=&#038;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://exchws.wordpress.com/2011/12/13/where-is-the-exchange-web-services-managed-api-1-2-sdk/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://0.gravatar.com/avatar/39f4677edceea82afcd097ef35e3043d?s=96&#38;d=http%3A%2F%2F0.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">liviojoao</media:title>
		</media:content>
	</item>
	</channel>
</rss>
