<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" version="2.0">

<channel>
	<title>Steve Goodman's Tech Blog - The weblog of an IT pro specialising in Exchange, Exchange, VMware, Servers and Storage</title>
	
	<link>http://www.stevieg.org</link>
	<description>Exchange, VMware, Servers and Storage News, Hints and Tips</description>
	<lastBuildDate>Wed, 01 Sep 2010 09:19:25 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/stevieg" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="stevieg" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Publishing IMAP, POP and SMTP settings via Exchange 2010 OWA</title>
		<link>http://www.stevieg.org/2010/08/publishing-imap-pop-and-smtp-settings-via-exchange-2010-owa/</link>
		<comments>http://www.stevieg.org/2010/08/publishing-imap-pop-and-smtp-settings-via-exchange-2010-owa/#comments</comments>
		<pubDate>Tue, 31 Aug 2010 22:27:41 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Client Access]]></category>
		<category><![CDATA[ecp]]></category>
		<category><![CDATA[Exchange 2010]]></category>
		<category><![CDATA[IMAP]]></category>
		<category><![CDATA[OWA]]></category>
		<category><![CDATA[POP]]></category>
		<category><![CDATA[Publish Settings]]></category>
		<category><![CDATA[SMTP]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=507</guid>
		<description><![CDATA[Do you allow your users to connect to Exchange 2010 directly via IMAP, POP and SMTP? If you do then not only will some Exchange admins call you crazy…  but you'll probably have to document the client settings such as server names, port and encryption settings somewhere and distribute it to users.
In Exchange 2010 there [...]]]></description>
			<content:encoded><![CDATA[<p>Do you allow your users to connect to Exchange 2010 directly via IMAP, POP and SMTP? If you do then not only will some Exchange admins call you crazy…  but you'll probably have to document the client settings such as server names, port and encryption settings somewhere and distribute it to users.</p>
<p>In Exchange 2010 there is actually somewhere to publish these settings - and once configured your documentation won't need to be updated if the server details change. You'll find these settings by logging into OWA, and choosing Options. The link "Settings for POP, IMAP, and SMTP access…" should be shown on the default "My Account" page:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image116.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb96.png" border="0" alt="image" width="487" height="260" /></a></p>
<p>By default, nothing will be listed if you click the link:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image117.png"><img style="background-image: none; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb97.png" border="0" alt="image" width="244" height="226" /></a></p>
<p>To configure these links, it's a fairly straightforward process. Before you begin, you need to know what the settings should be and in the case of the SMTP settings, which receive connector on which Hub Transport this relates to.</p>
<p>First, you configure the Client Access servers for the POP and IMAP settings, using the Set-POPSettings and Set-IMAPSettings cmdlets with the -ExternalConnectionSettings parameter.</p>
<p>For each protocol you specify a colon-separated list of values for the ExternalConnectionSettings. For POP3 with TLS, this might be "casserver.contoso.com:110:tls" or POP3 with SSL might be "casserver.contoso.com:995:ssl". IMAP with TLS might be "casserver.contoso.com:143:tls" and IMAP with SSL might be "casserver.contoso.com:993:ssl".</p>
<p>Here's a quick example of the commands against my test setup:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Set<span style="color: pink;">-</span>POPSettings <span style="color: pink;">-</span>ExternalConnectionSettings <span style="color: #800000;">&quot;mail.contoso.com:110:tls&quot;</span><br />
Set<span style="color: pink;">-</span>IMAPSettings <span style="color: pink;">-</span>ExternalConnectionSettings <span style="color: #800000;">&quot;mail.contoso.com:143:tls&quot;</span></div></div>
<p>It's important to remember, you need to run the command on all Client Access servers users will access.</p>
<p>Next, you need to allow the receive connector that you want "published" to advertise it's settings. You do this with the Set-ReceiveConnector cmdlet specifying the -AdvertiseClientSettings:$true parameter and value.</p>
<p>In my example, I want to advertise the port 587 "client" receive connector on my Hub Transport server:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Set<span style="color: pink;">-</span>ReceiveConnector <span style="color: pink;">-</span>Identity <span style="color: #800000;">&quot;hubtransport\Client HUBTRANSPORT&quot;</span> <span style="color: pink;">-</span>AdvertiseClientSettings:$true</div></div>
<p>Finally, run iisreset to restart IIS on each Client Access Server, the log back into OWA (well, ECP) and test the "Settings for POP, IMAP, and SMTP access…"  link again. It should now show the settings specified:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image118.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb98.png" border="0" alt="image" width="262" height="291" /></a></p>
<p>For further reading check out <a href="http://technet.microsoft.com/en-us/library/aa998252.aspx">Set-IMAPSettings</a>, <a href="http://technet.microsoft.com/en-us/library/aa997154.aspx">Set-POPSettings</a> and <a href="http://technet.microsoft.com/en-us/library/bb125140.aspx">Set-ReceiveConnector</a>.</p>
<p>(Just a footnote- thanks to Jag at Microsoft for providing this information)</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/Pm7wxrrQNYDDdm6s0AIRMoz7Ynk/0/da"><img src="http://feedads.g.doubleclick.net/~a/Pm7wxrrQNYDDdm6s0AIRMoz7Ynk/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/Pm7wxrrQNYDDdm6s0AIRMoz7Ynk/1/da"><img src="http://feedads.g.doubleclick.net/~a/Pm7wxrrQNYDDdm6s0AIRMoz7Ynk/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/ewk49WxcsC0" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/08/publishing-imap-pop-and-smtp-settings-via-exchange-2010-owa/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Auto-mapping shared mailboxes in Exchange 2010 SP1 with Outlook 2010</title>
		<link>http://www.stevieg.org/2010/08/auto-mapping-shared-mailboxes-in-exchange-2010-sp1-with-outlook-2010/</link>
		<comments>http://www.stevieg.org/2010/08/auto-mapping-shared-mailboxes-in-exchange-2010-sp1-with-outlook-2010/#comments</comments>
		<pubDate>Mon, 30 Aug 2010 23:23:18 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Outlook]]></category>
		<category><![CDATA[additional mailboxes]]></category>
		<category><![CDATA[Auto mapping]]></category>
		<category><![CDATA[auto mounting]]></category>
		<category><![CDATA[Exchange 2010]]></category>
		<category><![CDATA[New Feature]]></category>
		<category><![CDATA[Shared Mailboxes]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=497</guid>
		<description><![CDATA[If you've read the Exchange Team Blog's announcement for SP1 you may have noticed one of the new features mentioned that isn't so widely publicised:
"On the client side features like auto mapping of shared mailboxes to user’s Outlook 2010 profiles will remove a support headache."
As it's one of my favourite new features and there's not [...]]]></description>
			<content:encoded><![CDATA[<p>If you've read the Exchange Team Blog's <a href="http://msexchangeteam.com/archive/2010/08/25/455861.aspx" target="_blank">announcement</a> for SP1 you may have noticed one of the new features mentioned that isn't so widely publicised:</p>
<blockquote><p>"On the client side features like auto mapping of shared mailboxes to user’s Outlook 2010 profiles will remove a support headache."</p></blockquote>
<p>As it's one of my favourite new features and there's not much documentation yet, I wanted to write a little more about the feature and demonstrate how it works in practice.</p>
<p><strong>How it works</strong></p>
<p>When you add full mailbox permissions on Exchange 2010 SP1 to a new or existing shared mailbox that's also on SP1, Exchange now updates an Active Directory attribute on the shared mailbox itself, named msExchDelegateListLink. This is a multi-value attribute containing a list of DNs (Distinguished Names) of the other mailboxes that have full access to the mailbox and should auto-map that mailbox:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image191.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image[19]" src="http://www.stevieg.org/wp-content/uploads/image19_thumb.png" border="0" alt="image[19]" width="290" height="259" /></a></p>
<p>When Outlook 2010 launches it searches for mailboxes that have the user's mailbox DN listed and displays them below the user's primary mailbox.</p>
<p>In previous versions this was accomplished by going to the user's Exchange accounts settings, going to "More Settings", choosing "Advanced" and entering the shared mailbox manually under "Open these additional mailboxes" as shown below.</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image112.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb92.png" border="0" alt="image" width="190" height="94" /></a></p>
<p>For any organisation making use of a large number of shared mailboxes this is a bit of a pain as IT needs to both write documentation so users can do this themselves and in many cases do it for the user. The new feature simply removes this step.</p>
<p>The catch (!) is that just moving a shared mailbox to SP1 or upgrading isn't enough to enable the feature. As it's an extra attribute added at the same time as the permissions, you need to remove and re-add the permissions via the normal way (EMC or Powershell's Remove-MailboxPermission/Add-MailboxPermission) to make this take effect, or do it yourself via ADSI scripting/AD Powershell (probably not very supported!).</p>
<p><strong>Demonstration</strong></p>
<p>Just to give you a quick demo of how simple this is, all you need to do is add permissions on the Shared Mailbox in the normal way:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image113.png"><img style="background-image: none; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb93.png" border="0" alt="image" width="244" height="151" /></a></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image114.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb94.png" border="0" alt="image" width="332" height="290" /></a></p>
<p>Then on the client, close and ppen Outlook. The Shared Mailbox should show after a few seconds:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image115.png"><img style="background-image: none; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb95.png" border="0" alt="image" width="200" height="244" /></a></p>
<p>Yes, it's really that simple. Simple enough that you might use it without even noticing and wonder how that shared mailbox got mapped in the first place.. But I think it's definitely going to be a feature any IT department that routinely adds/removes permissions for mailboxes this way will appreciate.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/970Lf7M8ZduZLvTtiqW0P9QhJdo/0/da"><img src="http://feedads.g.doubleclick.net/~a/970Lf7M8ZduZLvTtiqW0P9QhJdo/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/970Lf7M8ZduZLvTtiqW0P9QhJdo/1/da"><img src="http://feedads.g.doubleclick.net/~a/970Lf7M8ZduZLvTtiqW0P9QhJdo/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/kGA6jq9R5jo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/08/auto-mapping-shared-mailboxes-in-exchange-2010-sp1-with-outlook-2010/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Sync a text file to an Exchange distribution group</title>
		<link>http://www.stevieg.org/2010/08/sync-a-text-file-to-an-exchange-distribution-group/</link>
		<comments>http://www.stevieg.org/2010/08/sync-a-text-file-to-an-exchange-distribution-group/#comments</comments>
		<pubDate>Mon, 30 Aug 2010 07:54:54 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Distribution Group]]></category>
		<category><![CDATA[Exchange 2007]]></category>
		<category><![CDATA[Exchange 2010]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=483</guid>
		<description><![CDATA[Just a quick one for this bank holiday morning.
Here's a little bit of code that you can use to synchronise a text file with a list of recipient primary email addresses to a distribution group. A good use for it would be where you have exports from an application system to determine mailing lists that [...]]]></description>
			<content:encoded><![CDATA[<p>Just a quick one for this bank holiday morning.</p>
<p>Here's a little bit of code that you can use to synchronise a text file with a list of recipient primary email addresses to a distribution group. A good use for it would be where you have exports from an application system to determine mailing lists that the users should be a member of, and want to keep the two in sync.</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;height:400px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #800080;">$File</span><span style="color: pink;">=</span><span style="color: #008080; font-weight: bold;">Get-Content</span> <span style="color: #800000;">&quot;.\testdg.txt&quot;</span><br />
<span style="color: #800080;">$DG</span><span style="color: pink;">=</span><span style="color: #800000;">&quot;testdg&quot;</span><br />
<span style="color: #000000;">&#91;</span><span style="color: #008080;">array</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$DGmembers</span><span style="color: pink;">=</span>Get<span style="color: pink;">-</span>DistributionGroupMember <span style="color: #800080;">$DG</span><br />
<span style="color: #008000;"># Remove users who aren't in this group</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$DGmembers</span>.Count<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$i</span> <span style="color: #0000FF;">in</span> <span style="color: #800080;">$DGmembers</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$File</span> <span style="color: #FF0000;">-notcontains</span> <span style="color: #800080;">$i</span>.PrimarySMTPAddress<span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008080; font-weight: bold;">Write-Host</span> <span style="color: #800000;">&quot;Removing $($i.PrimarySMTPAddress) from $($DG)&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Remove<span style="color: pink;">-</span>DistributionGroupMember <span style="color: #800080;">$DG</span> <span style="color: pink;">-</span>Member <span style="color: #800080;">$i</span>.PrimarySMTPAddress <span style="color: #008080; font-style: italic;">-Confirm</span>:<span style="color: #800080;">$false</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #008000;"># Add new members</span><br />
<span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$i</span> <span style="color: #0000FF;">in</span> <span style="color: #800080;">$File</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span><span style="color: #800080;">$DGmembers</span> <span style="color: pink;">|</span> <span style="color: #0000FF;">Where</span> <span style="color: #000000;">&#123;</span> <a href="about:blank"><span style="color: #000080;">$_</span></a>.PrimarySMTPAddress <span style="color: #FF0000;">-eq</span> <span style="color: #800080;">$i</span> <span style="color: #000000;">&#125;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>Recipient <span style="color: #800080;">$i</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008080; font-weight: bold;">Write-Host</span> <span style="color: #800000;">&quot;Adding $($i) to $($DG)&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Add<span style="color: pink;">-</span>DistributionGroupMember <span style="color: #800080;">$DG</span> <span style="color: pink;">-</span>Member <span style="color: #800080;">$i</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008080; font-weight: bold;">Write-Host</span> <span style="color: #FF0000;">-f</span> Red <span style="color: pink;">-</span>b Black <span style="color: #800000;">&quot;Could not add $($i) to $($DG) - Recipient not found&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span></div></div>
<p>The format of the input file is simply - just the primary email addresses, one per line.</p>
<p>Steve</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/0Qda7a-FxzIw8SYJL-JkFqncu9g/0/da"><img src="http://feedads.g.doubleclick.net/~a/0Qda7a-FxzIw8SYJL-JkFqncu9g/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/0Qda7a-FxzIw8SYJL-JkFqncu9g/1/da"><img src="http://feedads.g.doubleclick.net/~a/0Qda7a-FxzIw8SYJL-JkFqncu9g/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/hvGDN-GUmds" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/08/sync-a-text-file-to-an-exchange-distribution-group/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Set up Federated Free/Busy and Calendar Sharing between Exchange 2010 SP1 and Outlook Live</title>
		<link>http://www.stevieg.org/2010/08/federation-onpremise-outlooklive/</link>
		<comments>http://www.stevieg.org/2010/08/federation-onpremise-outlooklive/#comments</comments>
		<pubDate>Sun, 29 Aug 2010 08:43:55 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Federation]]></category>
		<category><![CDATA[Outlook Live]]></category>
		<category><![CDATA[Calendar Sharing]]></category>
		<category><![CDATA[ecp]]></category>
		<category><![CDATA[Education]]></category>
		<category><![CDATA[Exchange 2010]]></category>
		<category><![CDATA[Exchange2010]]></category>
		<category><![CDATA[Free/Busy]]></category>
		<category><![CDATA[Live@EDU]]></category>
		<category><![CDATA[outlook live]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Self-signed certificate]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=363</guid>
		<description><![CDATA[As organizations move to make use of cloud based services, like Exchange Online or Outlook Live, it’s pretty important to be able to integrate both the on-premise service and the cloud service so that end-users can continue to work as normal. That’s especially important with a service like Outlook Live, aimed at Education institutions, where [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft" style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0pt none;" title="image" src="http://www.stevieg.org/wp-content/uploads/image551.png" border="0" alt="image" width="199" height="137" align="alignleft" />As organizations move to make use of cloud based services, like Exchange Online or Outlook Live, it’s pretty important to be able to integrate both the on-premise service and the cloud service so that end-users can continue to work as normal. That’s especially important with a service like Outlook Live, aimed at Education institutions, where typically staff, faculty and some students will continue to be hosted on-premise and the majority of students will be hosted in the cloud. A seamless experience makes life easier for users and thus easier for IT…</p>
<p>So, with Outlook Live and Exchange 2010 On-Premise there is a pretty good opportunity to get Exchange working seamlessly between both systems. I’ll be covering a unified login in a further article (once I’ve re-written the code we use in-house into a re-distributable form) and if there’s any interest I’m also happy to cover using a single autodiscover service as well. But for now, I’m focusing on the user experience with free/busy and calendar sharing.</p>
<p>One of the areas might expect to <img class="right alignright" style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0pt none;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb78.png" border="0" alt="image" width="302" height="122" />“just work” is free/busy and calendar sharing between on-premise and cloud. The options are there, it looks like it tries to do it.. But the end user ust gets unfriendly error messages and “permission denied” errors. To get this up and running in Exchange 2010 SP1 is actually now pretty simple. No expensive certificates required from a handful of providers – you can use a self-signed certificate and it’s easy enough to get up and running with in less than an hour. In this article, I’m going to show you how…</p>
<h5>Pre-requisites</h5>
<p>First things first, we need a few things in-place and working already before we can get going. The main pre-req is Autodiscover, but I won’t cover how to set this up, as it's is covered in detail elsewhere on the good old ‘net..</p>
<ul>
<li>
<div>Autodiscover working for On-Premise for the domain you want to use (using DNS names, not a service records)</div>
</li>
<li>
<div>Autodiscover working for Outlook Live for the domain you want to use (again, using DNS names, not a service record)</div>
</li>
<li>
<div>Separate domains for on-premise and Outlook Live (I’m testing getting shared working – follow up article to come)</div>
</li>
<li>
<div>Exchange 2010 CAS Connectivity to *.outlook.com</div>
</li>
<li>
<div>Org admin rights on Exchange 2010 SP1 and Tenant Admin rights on Outlook Live, along with Powershell access to both.</div>
</li>
<li>
<div>Access to manage the DNS for both domains and add TXT records.</div>
</li>
</ul>
<p>Once that’s all setup and available, you should be ready to go..</p>
<h5>Setting it up</h5>
<p>To keep things simple, we’re not going to do anything too complicated, we’re going to set things up so all users in both on-premise and Outlook Live can see each other’s free/busy and share calendars (and contacts). Also, for the purposes of this article it’s assumed no Sharing Policy is setup already.</p>
<p>On our test setup, we’ve got two domains:<br />
<strong>On Premise:</strong> contoso.astonuniversity.net<br />
<strong>Outlook Live: </strong>live.contoso.astonuniversity.net</p>
<p>Basically we need to create three things on-premise – A Federation Trust to authenticate us against the MS Federation Gateway, then an Organization Relationship to say Outlook Live can see in for Free busy, and finally a Sharing Policy to allow on-premise users to share their calendars with Outlook Live users. In Outlook Live the trust with MS’s Federation Gateway is there by default so we just need the Organization Relationship to allow On-premise to see in and the Sharing Policy to allow the Outlook Live users to share with On-premise users.</p>
<p>First, we’ll setup the on-premise config, then get the Outlook Live stuff done. Afterwards we’ll test everything works.</p>
<h6>On Premise Config</h6>
<p><strong>Step One – Setup a New Federation Trust using a self – signed certificate</strong></p>
<p>First you need to make a new certificate. Create one using the following command:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">New<span style="color: pink;">-</span>ExchangeCertificate <span style="color: pink;">-</span>DomainName <span style="color: #800000;">'Federation'</span> <span style="color: pink;">-</span>FriendlyName <span style="color: #800000;">'Exchange Delegation Federation'</span> <span style="color: pink;">-</span>KeySize <span style="color: #800000;">'2048'</span> <span style="color: pink;">-</span>Services <span style="color: #800000;">'Federation'</span> <span style="color: pink;">-</span>SubjectKeyIdentifier <span style="color: #800000;">'67653b80cfcb4cd18f7ac952fed0e590'</span> <span style="color: pink;">-</span>PrivateKeyExportable $true</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image68.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb49.png" border="0" alt="image" width="640" height="57" /></a></p>
<p>Note down the <strong>Thumbprint</strong> in the output, and then create the Federation Trust using that thumbprint value. Note that we’re manually setting the MetaDataURL. This is why we can’t do it in the Exchange Management Console – SP1 by default works against a new “Business” gateway. Outlook Live currently works against a legacy “Consumer” gateway and the URL below switches us to use that one.</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">New<span style="color: pink;">-</span>FederationTrust <span style="color: #008080; font-style: italic;">-Name</span> <span style="color: #800000;">'Microsoft Federation Gateway'</span> <span style="color: pink;">-</span>Thumbprint <span style="color: #800000;">'thumbprint'</span> –metadataurl https:<span style="color: pink;">//</span>nexus.passport.com<span style="color: pink;">/</span>FederationMetadata<span style="color: pink;">/</span><span style="color: #804000;">2006</span><span style="color: pink;">-</span><span style="color: #804000;">12</span><span style="color: pink;">/</span>FederationMetadata.xml</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image70.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb51.png" border="0" alt="image" width="640" height="97" /></a></p>
<p>Next, we need to setup a record in DNS that will be used to verify we own the domain and allocate us an ApplicationID for our domain.</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>FederatedDomainProof <span style="color: pink;">-</span>DomainName contoso.astonuniversity.net</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image73.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb54.png" border="0" alt="image" width="640" height="95" /></a></p>
<p>Copy “Proof” entry that is output, and get ready to enter it into DNS (BTW the DnsRecord syntax will be wrong, just ignore it)</p>
<p>If you use Windows DNS, it goes a little something like this:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image74.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb55.png" border="0" alt="image" width="226" height="152" align="left" /></a> <a href="http://www.stevieg.org/wp-content/uploads/image75.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb56.png" border="0" alt="image" width="222" height="219" /></a> <a href="http://www.stevieg.org/wp-content/uploads/image76.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb57.png" border="0" alt="image" width="220" height="244" /></a></p>
<p>And if it’s Unix:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image77.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb58.png" border="0" alt="image" width="479" height="27" /></a></p>
<p>Once that’s in, reload/HUP your DNS and make sure you can resolve it, both from your Exchange servers and from the outside world. The following command should work:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">nslookup -querytype=TXT contoso.astonuniversity.net</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image109.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb90.png" border="0" alt="image" width="468" height="86" /></a></p>
<p>Now we’ve got the Federated Trust and DNS record sorted, we can get ourselves properly setup with the Federated Gateway. To do this, we use the Set-FederatedOrganizationIdentifier command:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Set<span style="color: pink;">-</span>FederatedOrganizationIdentifier <span style="color: pink;">-</span>DelegationFederationTrust <span style="color: #800000;">'Microsoft Federation Gateway'</span> <span style="color: pink;">-</span>AccountNamespace contoso.astonuniversity.net <span style="color: pink;">-</span>Enabled:$true</div></div>
<p>Assuming that completes successfully, we can move onto the next step..</p>
<p><strong>Step Two– Setup the On-Premise Organization Relationship</strong></p>
<p>The next step is to allow our Outlook Live domain to see our On-premise Free/Busy info. You can do this via Powershell or the Exchange Management Console:</p>
<p>Via Powershell:</p>
<p>Test that you can get the federation info for your Outlook Live domain. If you get an error, run the command again with the -Verbose parameter for a detailed error and check your autodiscover setup for Outlook Live:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>FederationInformation live.contoso.astonuniversity.net</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image80.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb61.png" border="0" alt="image" width="644" height="106" /></a></p>
<p>Next, configure the relationship. The LimitedDetails option below is the most open setting for the relationship, which means any user who has chosen to show that much detail will also make it available to the Outlook Live tenant.</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>FederationInformation live.contoso.astonuniversity.net <span style="color: pink;">|</span> New<span style="color: pink;">-</span>OrganizationRelationship <span style="color: #008080; font-style: italic;">-Name</span> <span style="color: #800000;">&quot;Outlook Live&quot;</span> <span style="color: pink;">-</span>FreeBusyAccessEnabled:<span style="color: #800080;">$true</span> <span style="color: pink;">-</span>FreeBusyAccessLevel:LimitedDetails</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image81.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb62.png" border="0" alt="image" width="644" height="64" /></a></p>
<p>If you'd rather configure via Exchange Management Console:</p>
<p>Navigate to Organization Configuration, and select the Organization Relationships Tab. Right click in the whitespace and choose “New Organization Relationship”:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image83.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb64.png" border="0" alt="image" width="375" height="236" /></a></p>
<p>in the New Organization Relationship window, Give a the new relationship a friendly name (e.g. Outlook Live).  Select the checkbok "Enable this organization relationship", then choose to enable free/busy access. Choose “Free/busy access with time, plus subject and location” to select the widest access. This means any user who has chosen to show that much detail (i.e. people can see that on-premise right now) will also share it to Outlook Live.</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image84.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb65.png" border="0" alt="image" width="435" height="383" /></a></p>
<p>Next enter the Outlook Live domain in the Automatically discover configuration information text box, and press Next.</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image85.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb66.png" border="0" alt="image" width="441" height="386" /></a></p>
<p>Check for any errors, and press Finish. If there are errors, and it isn't a typo, then it’s likely to be an Autodiscover issue -  but  you'll find out most detail on the possible cause if you use the  Powershell instructions above.</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image86.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb67.png" border="0" alt="image" width="448" height="392" /></a></p>
<p>The new relationship should now be listed underneath Organization Relationships:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image87.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb68.png" border="0" alt="image" width="395" height="112" /></a></p>
<p><strong>Step 3 – Setup the Sharing Policy</strong></p>
<p>To enable our on-premise users to share their information with Outlook Live users we need a sharing policy setup. While you can setup multiple sharing policies and assign them to different users, for this basic sharing we’re going to modify the default sharing policy</p>
<p>Via Powershell:</p>
<p>First, check your settings. Note down the existing Domains value.</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>SharingPolicy <span style="color: #800000;">'Default Sharing Policy'</span></div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image88.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb69.png" border="0" alt="image" width="473" height="49" /></a></p>
<p>Replace the domains value on the Default Sharing Policy setting the original value (or remove it, if you want) and adding the Outlook Live domain. For the Outlook Live domain we're setting the maximum scope for sharing:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Set<span style="color: pink;">-</span>SharingPolicy <span style="color: #800000;">'Default Sharing Policy'</span> –Domains <span style="color: #800000;">'*:CalendarSharingFreeBusySimple'</span><span style="color: pink;">,</span> <span style="color: #800000;">'live.contoso.astonuniversity.net:CalendarSharingFreeBusyReviewer, ContactsSharing'</span></div></div>
<p>If you'd prefer to configure the sharing policy via the Exchange Management Console:</p>
<p>Navigate to Organization Configuration &gt; Mailbox &gt; Sharing Policies, then right click the Default Sharing Policy, then choose Properties:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image89.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb70.png" border="0" alt="image" width="538" height="180" /></a></p>
<p>In the Default Sharing Policy Properties, choose “Add”, then specify the Outlook Live domain. To allow for the maxium level of detail to be shared by individual users,  select the last option “Calendar sharing with free/busy information plus subject, location and body, Contacts sharing:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image90.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb71.png" border="0" alt="image" width="331" height="369" /></a><a href="http://www.stevieg.org/wp-content/uploads/image91.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb72.png" border="0" alt="image" width="363" height="189" /></a></p>
<p>And that’s it for On-Premise. Next.. We need to get the hosted environment setup with with the corresponding parameters:</p>
<p><strong>Outlook Live Setup</strong></p>
<p>For the Outlook Live setup you have to use Powershell – Exchange Management Shell isn’t supported when managing your hosted tenant. If you’re not sure how to connect Powershell see <a href="http://help.outlook.com/en-us/140/cc546278.aspx" target="_blank">the guide on the Outlook.com help site</a>, but it basically looks a little like this:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image92.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb73.png" border="0" alt="image" width="644" height="80" /></a></p>
<p><strong>Step 1: Setup the Outlook Live Organization Relationship</strong></p>
<p>We get to miss out the first step that we had to do on-premise, setup of the federation trust, because as a tenant of the outlook.com Exchange environment this has already in place.. So we can skip to getting an organization relationship setup with our on-premise domain.</p>
<p>First, we check that we can indeed discover the correct settings by using the Get-FederationInformation command, specifying the on-premise domain:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>FederationInformation contoso.astonuniversity.net</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image93.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb74.png" border="0" alt="image" width="644" height="91" /></a></p>
<p>The output from the command should show details matching the Organization Identifier and Application URI we setup earlier, along with the details of the on-premise Autodiscover environment.</p>
<p>If it returns a failure you may need to double check your Autodiscover settings for the on-premise environment, or in some cases you may need to give it a little while (if you just setup your Federation Trust on-premise) and try again. For example, in my production environment it took around an hour for my production Outlook Live tenant to be able to discover the Federation Information although my test domains could see the same information without any issues.</p>
<p>So.. After you’ve tested Outlook Live can discover the Federation Information, it’s onto actually creating the Organization Relationship. The command is exactly the same as on-premise,we are really just swapping the domain:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>FederationInformation contoso.astonuniversity.net <span style="color: pink;">|</span> New<span style="color: pink;">-</span>OrganizationRelationship <span style="color: #008080; font-style: italic;">-Name</span> <span style="color: #800000;">&quot;On-Premise&quot;</span> <span style="color: pink;">-</span>FreeBusyAccessEnabled:<span style="color: #800080;">$true</span> <span style="color: pink;">-</span>FreeBusyAccessLevel:LimitedDetails</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image94.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb75.png" border="0" alt="image" width="644" height="62" /></a></p>
<p><strong>Step 2: Setup the sharing policy</strong></p>
<p>Finally, it’s on to the final step – getting the sharing policy sorted. Check out what the Default Sharing Policy currently is before we go and add our on-premise domain:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>SharingPolicy</div></div>
<p><a href="http://www.stevieg.org/wp-content/uploads/image95.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb76.png" border="0" alt="image" width="644" height="76" /></a></p>
<p>Then replace the Domains list for the Default Sharing Policy with a value that includes the on-premise domain. In the example below, I’m keeping the settings that were already there and adding the on-premise domain. For consistency, I'm also keeping the same sharing level as set on-premise:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Set<span style="color: pink;">-</span>SharingPolicy <span style="color: #800000;">'Default Sharing Policy'</span> <span style="color: pink;">-</span>Domains <span style="color: #800000;">'*:CalendarSharingFreeBusySimple'</span><span style="color: pink;">,</span> <span style="color: #800000;">'contoso.astonuniversity.net:CalendarSharingFreeBusyReviewer, ContactsSharing'</span></div></div>
<p>After that, it should all be done. Give it a little bit of time (say, 15 minutes) for everything to take effect and we should be ready to have a play..</p>
<p><strong>Testing it out</strong></p>
<p>For testing purposes on my two domains, on-premise “contoso.astonuniversity.net” and Outlook Live “live.contoso.astonuniversity.net”, I’ve created test accounts in each –“onpremise@contoso.astonuniversity.net” and “outlooklive@live.contoso.astonuniversity.net”. For the screenshots I’ve used OWA, but it works equally well in Outlook.</p>
<p>The first test is for Free/Busy. I’ve created a few test appointments in both calendars and you’ll see availability works just as if the user was on-premise:</p>
<p>In Outlook Live, scheduling a new meeting with the on-premise user as an attendee:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image98.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb79.png" border="0" alt="image" width="644" height="477" /></a></p>
<p>Next, via on-premise Exchange 2010 SP1, with our Outlook Live user as an attendee this time:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image104.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb85.png" border="0" alt="image" width="644" height="454" /></a></p>
<p>The second test is to check it is possible to share a calendar either way, and this is where it strays slightly away from the full range of options available to users within a single environment.</p>
<p>The limitations we’ve got mean that the user must share the calendar using OWA or Outlook 2010, and must use the “share this calendar” options rather than setting permissions directly. The recipient of the permission must add the calendar using the resulting email (they can’t just add it by name) and it’s read-only. this of course means the process can’t be easily automated, but it does allow users to use a common workflow to share folders, via the “share” options.</p>
<p>Sharing a calendar in Outlook Live:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image99.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb80.png" border="0" alt="image" width="452" height="176" /></a></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image100.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb81.png" border="0" alt="image" width="454" height="289" /></a></p>
<p>On-premise user receives the sharing invitation and chooses “Add this calendar” to add it:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image101.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb82.png" border="0" alt="image" width="644" height="268" /></a></p>
<p>After adding the calendar, it’s shown in red (in OWA, anyway) while the server retrieves the calendar:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image102.png"><img style="background-image: none; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb83.png" border="0" alt="image" width="244" height="31" /></a></p>
<p>After a minute or so, the Outlook Live calendar shows up alongside the On-premise calendar:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image103.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb84.png" border="0" alt="image" width="644" height="329" /></a></p>
<p>Finally, let's test it from On-premise to Outlook Live:</p>
<p>Select the Calendar’s “Share” option to share the calendar (it's worth noting that the OWA UI has changed between RTM and SP1.. but I digress):</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image105.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb86.png" border="0" alt="image" width="476" height="197" /></a></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image106.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb87.png" border="0" alt="image" width="483" height="230" /></a></p>
<p>Over in Outlook Live, the Outlook Live user receives the invitation and again, chooses the “Add this calendar” link:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image107.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb88.png" border="0" alt="image" width="644" height="273" /></a></p>
<p>After choosing to add the calendar, the on-premise calendar shows (again after a minute or so to do the first sync)  alongside the Outlook Live calendar:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image108.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb89.png" border="0" alt="image" width="644" height="328" /></a></p>
<p>Contacts sharing is again a similar process, although it must be shared using Outlook 2010. Simply right click a contacts folder and choose Share&gt;Share Contacts:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image110.png"><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: inline; padding-top: 0px; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb91.png" border="0" alt="image" width="244" height="171" /></a></p>
<p>And that’s it – hopefully this will work for you, but if you have any questions or any issues, just use the comments form below.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/ahYDgn2tg0oWIS8dkSDIyrm3tqI/0/da"><img src="http://feedads.g.doubleclick.net/~a/ahYDgn2tg0oWIS8dkSDIyrm3tqI/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/ahYDgn2tg0oWIS8dkSDIyrm3tqI/1/da"><img src="http://feedads.g.doubleclick.net/~a/ahYDgn2tg0oWIS8dkSDIyrm3tqI/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/GqKbDpU-xIA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/08/federation-onpremise-outlooklive/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Exchange 2010 SP1 is now available!</title>
		<link>http://www.stevieg.org/2010/08/exchange-2010-sp1-is-now-available/</link>
		<comments>http://www.stevieg.org/2010/08/exchange-2010-sp1-is-now-available/#comments</comments>
		<pubDate>Wed, 25 Aug 2010 16:17:58 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Exchange2010 exchangeserver2010]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=449</guid>
		<description><![CDATA[Finally after many months of testing, Exchange Server 2010 SP1, build 218.15  is available for public download.
Read more (including my comments) over on the Exchange Team Blog or download direct from the Microsoft website.
Quick tip - if you're planing on installing, make sure you check out the pre-reqs.. You WILL need to install quite a [...]]]></description>
			<content:encoded><![CDATA[<p>Finally after many months of testing, Exchange Server 2010 SP1, build 218.15  is available for public download.</p>
<p>Read more (including my comments) over on the<a href="http://msexchangeteam.com/archive/2010/08/25/455861.aspx"> Exchange Team Blog</a> or <a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=50b32685-4356-49cc-8b37-d9c9d4ea3f5b&amp;displaylang=en">download direct</a> from the Microsoft website.</p>
<p>Quick tip - if you're planing on installing, make sure you <a href="http://technet.microsoft.com/en-us/library/bb691354%28EXCHG.141%29.aspx">check out the pre-reqs</a>.. You WILL need to install quite a few.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/wvJHCzwbop_sMn_xtXLaokHOUXM/0/da"><img src="http://feedads.g.doubleclick.net/~a/wvJHCzwbop_sMn_xtXLaokHOUXM/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/wvJHCzwbop_sMn_xtXLaokHOUXM/1/da"><img src="http://feedads.g.doubleclick.net/~a/wvJHCzwbop_sMn_xtXLaokHOUXM/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/0DsWQOHSnsw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/08/exchange-2010-sp1-is-now-available/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Powershell to import contacts into Exchange and Outlook Live</title>
		<link>http://www.stevieg.org/2010/07/using-powershell-to-import-contacts-into-exchange-and-outlook-live/</link>
		<comments>http://www.stevieg.org/2010/07/using-powershell-to-import-contacts-into-exchange-and-outlook-live/#comments</comments>
		<pubDate>Sun, 25 Jul 2010 21:56:29 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[EWS]]></category>
		<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Outlook Live]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Exchange2010]]></category>
		<category><![CDATA[exchangeserver2010]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=336</guid>
		<description><![CDATA[When performing migrations between different systems, there’s always the case where the tools available don’t do the job out of the box – and although IMAP migration tools for Exchange and Outlook Live can be great for moving mail, there isn’t a decent free solution for importing contacts.
For a recent migration from a Unix system [...]]]></description>
			<content:encoded><![CDATA[<p>When performing migrations between different systems, there’s always the case where the tools available don’t do the job out of the box – and although IMAP migration tools for Exchange and Outlook Live can be great for moving mail, there isn’t a decent free solution for importing contacts.</p>
<p>For a recent migration from a Unix system (Dovecot + SquirrelMail) to Outlook Live, I came across this very scenario. While Microsoft provide IMAP migration tools to move mail to Outlook Live (which I was lucky enough to beta test before it was widely available), no tools are provided to move other data such as contacts and calendars.</p>
<p>While this isn’t the actual code I used (I wrote my original code in C#), I’ve re-visited what I’ve done and listened to what others say they need. What I’ve heard is it would be useful to have some Powershell code that out-of-the box can import contacts into any Exchange mailbox. The reason that Powershell is the right language for code like this is that it’s fairly easy for the enterprising administrator to modify to their needs.</p>
<h5>Getting started</h5>
<p>Before you can run this script, there are a few things you need to set up first. Don’t worry though! It’s nothing too onerous – all is needed to get going is two things:</p>
<ol>
<li>Setup of EWS  impersonation, unless you only want to work with accounts you know the username/password for.</li>
<li>Installing the Managed API DLL onto your computer.</li>
</ol>
<p><strong>Setup of Exchange Web Services Impersonation<br />
</strong>Exchange Web Services is the programmatic interface to each user’s Exchange mailbox. Most actions that can be performed in Outlook can be performed via EWS – so much so, in fact, that Apple’s <a href="http://images.apple.com/macosx/exchange/docs/MacOSXSL_Exchange.pdf">Mail.app</a> in Snow Leopard and the <a href="http://www.microsoft.com/mac/itpros/entourage-ews.mspx">latest update</a> for Entourage 2008 use EWS as the backend for the mail clients themselves.</p>
<p>If you’re planning on doing a mass-import of contacts, or don’t know the user’s password you’re importing, then setup of EWS impersonation is the step you need to take to allow a trusted account to switch to the user you want to import.</p>
<p>In Exchange 2010, setup of Exchange impersonation is managed via <a href="http://msexchangeteam.com/archive/2009/11/16/453222.aspx" target="_blank">RBAC</a>. Full details of how to setup impersonal are <a href="http://msdn.microsoft.com/en-us/library/bb204095.aspx" target="_blank">on the Microsoft site</a>, but if you just want to get it setup for a single admin/service account, org-wide, use the following command substituing <em>serviceaccount</em> for your service account:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">New<span style="color: pink;">-</span>ManagementRoleAssignment <span style="color: #008080; font-style: italic;">-Name</span>:impersonationAssignmentName <span style="color: #008080; font-style: italic;">-Role</span>:ApplicationImpersonation <span style="color: pink;">-</span>User:serviceaccount</div></div>
<p>On Exchange 2007, it’s very different, and is managed by AD permissions on individual Client Access Servers. Again – <a href="http://msdn.microsoft.com/en-us/library/bb204095%28EXCHG.80%29.aspx" target="_blank">full details on the Microsoft site</a>, but to add the permission to all CAS servers, the following code will suffice, again substituting <em>serviceaccount </em>for your Service account:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>ExchangeServer <span style="color: pink;">|</span> <span style="color: #0000FF;">where</span> <span style="color: #000000;">&#123;</span><a href="about:blank"><span style="color: #000080;">$_</span></a>.IsClientAccessServer <span style="color: #FF0000;">-eq</span> <span style="color: #800080;">$TRUE</span><span style="color: #000000;">&#125;</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">ForEach-Object</span> <span style="color: #000000;">&#123;</span>Add<span style="color: pink;">-</span>ADPermission <span style="color: pink;">-</span>Identity <a href="about:blank"><span style="color: #000080;">$_</span></a>.distinguishedname <span style="color: pink;">-</span>User <span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>User <span style="color: pink;">-</span>Identity serviceaccount<span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">select-object</span><span style="color: #000000;">&#41;</span>.identity <span style="color: pink;">-</span>extendedRight ms<span style="color: pink;">-</span>Exch<span style="color: pink;">-</span>EPI<span style="color: pink;">-</span>Impersonation<span style="color: #000000;">&#125;</span></div></div>
<p><strong></strong></p>
<p><strong>Installing the Exchange Web Services Managed API</strong><br />
Next, whatever environment you are in, you need a copy of the DLL file that provides the bits and pieces that make this all work. The easiest way to get up and running is to download the API (choosing the right version for your platform), and install it to it’s default location.</p>
<p><a href="http://www.microsoft.com/downloads/details.aspx?FamilyID=C3342FB3-FBCC-4127-BECF-872C746840E1&amp;amp;displaylang=en&amp;displaylang=en" target="_blank">Download the EWS Managed API from the Microsoft site</a></p>
<p>Once downloaded and installed, you should be good to go with script.</p>
<h5>Using the script <em>Import-MailboxContacts.ps1</em></h5>
<p>So, you’ve got impersonation setup if needed, got the EWS DLL on your machine. You should be good to go!</p>
<p>For each mailbox you want to import contacts from you need a separate CSV file. The format of the file is intentionally the same as Outlook will export in, mainly because a lot of apps already export in the format (Gmail does, for example) so you should find it easy to get test data, but if you haven’t I’ve included a sample file to get you started.</p>
<p>Along with the data, you also need, at a minimum, the mailbox email address to import to. This is used when impersonating, and for Autodiscover. If you’re not logged on as the user you want to use for the import, you can specify a username and password. Additionally, there’s a variety of options to specify the EWS Url manually, switching to the Exchange 2007 version of the API etc.</p>
<p><strong>Examples</strong></p>
<p>The first example is a straightforward import into the current logged-on user’s mailbox. We’re specifying the Email Address and the URL to EWS (to bypass Autodiscover):</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image66.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb47.png" border="0" alt="image" width="704" height="80" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">.\Import<span style="color: pink;">-</span>MailboxContacts.ps1 <span style="color: pink;">-</span>CSVFileName .\Contacts.csv <span style="color: pink;">-</span>EmailAddress steve<span style="color: pink;">@</span>goodman.net <span style="color: pink;">-</span>EwsUrl https:<span style="color: pink;">//</span>server<span style="color: pink;">/</span>EWS<span style="color: pink;">/</span>Exchange.asmx</div></div>
<p>As you can see in the above example – it’s all fairly straightforward. You’ll also see the output shows the contacts that have been created – you can use standard Powershell pipeling to export this data, pipe it to another command or filter it.</p>
<p>The second example is slightly more complicated, and reflects the main use case. We’re connecting to a remote exchange organisation, using Autodiscover to find the EWS address, enabling impersonation and providing credentials at the command line:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image67.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb48.png" border="0" alt="image" width="704" height="74" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">.\Import<span style="color: pink;">-</span>MailboxContacts.ps1 <span style="color: pink;">-</span>CSVFileName .\Contacts.csv –EmailAddress steve<span style="color: pink;">@</span>contoso.com <span style="color: pink;">-</span>Impersonate <span style="color: #800080;">$true</span> <span style="color: pink;">-</span>Username serviceaccount <span style="color: pink;">-</span>Password password <span style="color: pink;">-</span>Domain contoso</div></div>
<p>In addition to the options above, you can also specify the parameters -Exchange2007 $true and use -EWSManagedApiDLLFilePath to specify a different path the the EWS DLL.</p>
<p><strong>Powershell Code</strong></p>
<p>Finally, you’ll need a copy of the code to do all this. At the bottom of the post you’ll find a ZIP file containing the Import-MailboxContacts.ps1 file and a sample CSV file, and below you’ll see the code itself. Happy importing!</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;height:400px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br />48<br />49<br />50<br />51<br />52<br />53<br />54<br />55<br />56<br />57<br />58<br />59<br />60<br />61<br />62<br />63<br />64<br />65<br />66<br />67<br />68<br />69<br />70<br />71<br />72<br />73<br />74<br />75<br />76<br />77<br />78<br />79<br />80<br />81<br />82<br />83<br />84<br />85<br />86<br />87<br />88<br />89<br />90<br />91<br />92<br />93<br />94<br />95<br />96<br />97<br />98<br />99<br />100<br />101<br />102<br />103<br />104<br />105<br />106<br />107<br />108<br />109<br />110<br />111<br />112<br />113<br />114<br />115<br />116<br />117<br />118<br />119<br />120<br />121<br />122<br />123<br />124<br />125<br />126<br />127<br />128<br />129<br />130<br />131<br />132<br />133<br />134<br />135<br />136<br />137<br />138<br />139<br />140<br />141<br />142<br />143<br />144<br />145<br />146<br />147<br />148<br />149<br />150<br />151<br />152<br />153<br />154<br />155<br />156<br />157<br />158<br />159<br />160<br />161<br />162<br />163<br />164<br />165<br />166<br />167<br />168<br />169<br />170<br />171<br />172<br />173<br />174<br />175<br />176<br />177<br />178<br />179<br />180<br />181<br />182<br />183<br />184<br />185<br />186<br />187<br />188<br />189<br />190<br />191<br />192<br />193<br />194<br />195<br />196<br />197<br />198<br />199<br />200<br />201<br />202<br />203<br />204<br />205<br />206<br />207<br />208<br />209<br />210<br />211<br />212<br />213<br />214<br />215<br />216<br />217<br />218<br />219<br />220<br />221<br />222<br />223<br />224<br />225<br />226<br />227<br />228<br />229<br />230<br />231<br />232<br />233<br />234<br />235<br />236<br />237<br />238<br />239<br />240<br />241<br />242<br />243<br />244<br />245<br />246<br />247<br />248<br />249<br />250<br />251<br />252<br />253<br />254<br />255<br />256<br />257<br />258<br />259<br />260<br />261<br />262<br />263<br />264<br />265<br />266<br />267<br />268<br />269<br />270<br />271<br />272<br />273<br />274<br />275<br />276<br />277<br />278<br />279<br />280<br />281<br />282<br />283<br />284<br />285<br />286<br />287<br />288<br />289<br />290<br /></div></td><td><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0000FF;">param</span><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$CSVFileName</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$EmailAddress</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$Username</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$Password</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$Domain</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">bool</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$Impersonate</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$EwsUrl</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">string</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$EWSManagedApiDLLFilePath</span><span style="color: pink;">,</span><span style="color: #000000;">&#91;</span><span style="color: #008080;">bool</span><span style="color: #000000;">&#93;</span><span style="color: #800080;">$Exchange2007</span><span style="color: #000000;">&#41;</span>;<br />
<br />
<span style="color: #008000;">#</span><br />
<span style="color: #008000;"># Import-MailboxContacts.ps1</span><br />
<span style="color: #008000;">#</span><br />
<span style="color: #008000;"># By Steve Goodman, Use at your own risk.</span><br />
<span style="color: #008000;">#</span><br />
<span style="color: #008000;"># Parameters</span><br />
<span style="color: #008000;"># &nbsp;Mandatory:</span><br />
<span style="color: #008000;"># -CSVFileName : Filename of the CSV file to import contacts for this user from. Same format as Outlook Export.</span><br />
<span style="color: #008000;"># -EmailAddress : Account SMTP email address. Required, but only used when impersonating or with Autodiscover - otherwise uses the user you login as</span><br />
<span style="color: #008000;"># &nbsp;Optional:</span><br />
<span style="color: #008000;"># -Impersonate : Set to $true to use impersonation.</span><br />
<span style="color: #008000;"># -Username : The username to use. If this isn't specified (along with Password), attempts to use the logged on user.</span><br />
<span style="color: #008000;"># -Password : Used with above</span><br />
<span style="color: #008000;"># -Domain : Used with above - optional.</span><br />
<span style="color: #008000;"># -EwsUrl : The URL for EWS if you don't want to use Autodiscover. Typically https://casserver/EWS/Exchange.asmx</span><br />
<span style="color: #008000;"># -EWSManagedApiDLLFilePath : (Optional) Overwrite the filename and path to the DLL for EWS Managed API. By default, uses the default install location.</span><br />
<span style="color: #008000;"># -Exchange2007 : Set to $true to use the Exchange 2007 SP1+ version of the Managed API.</span><br />
<span style="color: #008000;">#</span><br />
<br />
<span style="color: #008000;"># Contact Mapping - this maps the attributes in the CSV file (left) to the attributes EWS uses.</span><br />
<span style="color: #008000;"># NB: If you change these, please note &quot;First Name&quot; is specified at line 102 as a required attribute and</span><br />
<span style="color: #008000;"># &quot;First Name&quot; and &quot;Last Name&quot; are hard coded at lines 187-197 when constructing NickName and FileAs.</span><br />
<span style="color: #800080;">$ContactMapping</span><span style="color: pink;">=@</span><span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;First Name&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;GivenName&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Middle Name&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;MiddleName&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Last Name&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Surname&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Company&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;CompanyName&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Department&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Department&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Job Title&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;JobTitle&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business Street&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Business:Street&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business City&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Business:City&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business State&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Business:State&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business Postal Code&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Business:PostalCode&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business Country/Region&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Business:CountryOrRegion&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home Street&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Home:Street&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home City&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Home:City&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home State&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Home:State&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home Postal Code&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Other:Home:PostalCode&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home Country/Region&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Home:CountryOrRegion&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other Street&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Other:Street&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other City&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Other:City&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other State&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Other:State&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other Postal Code&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Other:PostalCode&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other Country/Region&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Address:Other:CountryOrRegion&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Assistant's Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:AssistantPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business Fax&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:BusinessFax&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:BusinessPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Business Phone 2&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:BusinessPhone2&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Callback&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:CallBack&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Car Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:CarPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Company Main Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:CompanyMainPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home Fax&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:HomeFax&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:HomePhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Home Phone 2&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:HomePhone2&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;ISDN&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:ISDN&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Mobile Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:MobilePhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other Fax&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:OtherFax&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Other Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:OtherTelephone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Pager&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:Pager&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Primary Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:PrimaryPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Radio Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:RadioPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;TTY/TDD Phone&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:TtyTddPhone&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Telex&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Phone:Telex&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Anniversary&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;WeddingAnniversary&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Birthday&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Birthday&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;E-mail Address&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Email:EmailAddress1&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;E-mail 2 Address&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Email:EmailAddress2&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;E-mail 3 Address&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Email:EmailAddress3&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Initials&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Initials&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Office Location&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;OfficeLocation&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Manager's Name&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Manager&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Mileage&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Mileage&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Notes&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Body&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Profession&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Profession&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Spouse&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;SpouseName&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Web Page&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;BusinessHomePage&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #800000;">&quot;Contact Picture File&quot;</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Method:SetContactPicture&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># CSV File Checks</span><br />
<span style="color: #008000;"># Check filename is specified</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$CSVFileName</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Parameter CSVFileName must be specified&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Check file exists</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span><span style="color: #008080; font-weight: bold;">Get-Item</span> <span style="color: #008080; font-style: italic;">-Path</span> <span style="color: #800080;">$CSVFileName</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Please provide a valid filename for parameter CSVFileName&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Check file has required fields and check if is a single row, or multiple rows</span><br />
<span style="color: #800080;">$SingleItem</span> <span style="color: pink;">=</span> <span style="color: #800080;">$false</span>;<br />
<span style="color: #800080;">$CSVFile</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">Import-Csv</span> <span style="color: #008080; font-style: italic;">-Path</span> <span style="color: #800080;">$CSVFileName</span>;<br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$CSVFile</span>.<span style="color: #800000;">&quot;First Name&quot;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$SingleItem</span> <span style="color: pink;">=</span> <span style="color: #800080;">$true</span>;<br />
<span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$CSVFile</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">0</span><span style="color: #000000;">&#93;</span>.<span style="color: #800000;">&quot;First Name&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;File $($CSVFileName) must specify at least the field 'First Name'&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Check email address</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$EmailAddress</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Parameter EmailAddress must be specified&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$EmailAddress</span>.Contains<span style="color: #000000;">&#40;</span><span style="color: #800000;">&quot;@&quot;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Parameter EmailAddress does not appear valid&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Check EWS Managed API available</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$EWSManagedApiDLLFilePath</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$EWSManagedApiDLLFilePath</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;C:\Program Files\Microsoft\Exchange\Web Services\1.0\Microsoft.Exchange.WebServices.dll&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span><span style="color: #008080; font-weight: bold;">Get-Item</span> <span style="color: #008080; font-style: italic;">-Path</span> <span style="color: #800080;">$EWSManagedApiDLLFilePath</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;EWS Managed API not found at $($EWSManagedApiDLLFilePath). Download from http://bit.ly/9O7gLo&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Load EWS Managed API</span><br />
<span style="color: #000000;">&#91;</span>void<span style="color: #000000;">&#93;</span><span style="color: #000000;">&#91;</span>Reflection.Assembly<span style="color: #000000;">&#93;</span>::<span style="color: #800000;">LoadFile</span><span style="color: #000000;">&#40;</span><span style="color: #800000;">&quot;C:\Program Files\Microsoft\Exchange\Web Services\1.0\Microsoft.Exchange.WebServices.dll&quot;</span><span style="color: #000000;">&#41;</span>;<br />
<br />
<span style="color: #008000;"># Create Service Object</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Exchange2007</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$service</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.ExchangeService<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.ExchangeVersion<span style="color: #000000;">&#93;</span>::Exchange2007_SP1<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$service</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.ExchangeService<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.ExchangeVersion<span style="color: #000000;">&#93;</span>::Exchange2010<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #008000;"># Set credentials if specified, or use logged on user.</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Username</span> <span style="color: #FF0000;">-and</span> <span style="color: #800080;">$Password</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Domain</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$service</span>.Credentials <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> &nbsp;Microsoft.Exchange.WebServices.Data.WebCredentials<span style="color: #000000;">&#40;</span><span style="color: #800080;">$Username</span><span style="color: pink;">,</span><span style="color: #800080;">$Password</span><span style="color: pink;">,</span><span style="color: #800080;">$Domain</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$service</span>.Credentials <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> &nbsp;Microsoft.Exchange.WebServices.Data.WebCredentials<span style="color: #000000;">&#40;</span><span style="color: #800080;">$Username</span><span style="color: pink;">,</span><span style="color: #800080;">$Password</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <br />
<span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$service</span>.UseDefaultCredentials <span style="color: pink;">=</span> <span style="color: #800080;">$true</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<br />
<span style="color: #008000;"># Set EWS URL if specified, or use autodiscover if no URL specified.</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$EwsUrl</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$service</span>.URL <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Uri<span style="color: #000000;">&#40;</span><span style="color: #800080;">$EwsUrl</span><span style="color: #000000;">&#41;</span>;<br />
<span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; try <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$service</span>.AutodiscoverUrl<span style="color: #000000;">&#40;</span><span style="color: #800080;">$EmailAddress</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span> catch <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">throw</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Perform a test - try and get the default, well known contacts folder.</span><br />
<br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Impersonate</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$service</span>.ImpersonatedUserId <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.ImpersonatedUserId<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.ConnectingIdType<span style="color: #000000;">&#93;</span>::SmtpAddress<span style="color: pink;">,</span> <span style="color: #800080;">$EmailAddress</span><span style="color: #000000;">&#41;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
try <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$ContactsFolder</span> <span style="color: pink;">=</span> <span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.ContactsFolder<span style="color: #000000;">&#93;</span>::Bind<span style="color: #000000;">&#40;</span><span style="color: #800080;">$service</span><span style="color: pink;">,</span> <span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.WellKnownFolderName<span style="color: #000000;">&#93;</span>::Contacts<span style="color: #000000;">&#41;</span>;<br />
<span style="color: #000000;">&#125;</span> catch <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">throw</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Add contacts</span><br />
<span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactItem</span> <span style="color: #0000FF;">in</span> <span style="color: #800080;">$CSVFile</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #008000;"># If impersonate is specified, do so.</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Impersonate</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$service</span>.ImpersonatedUserId <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.ImpersonatedUserId<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.ConnectingIdType<span style="color: #000000;">&#93;</span>::SmtpAddress<span style="color: pink;">,</span> <span style="color: #800080;">$EmailAddress</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.Contact<span style="color: #000000;">&#40;</span><span style="color: #800080;">$service</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;First Name&quot;</span> <span style="color: #FF0000;">-and</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;Last Name&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.NickName <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;First Name&quot;</span> <span style="color: pink;">+</span> <span style="color: #800000;">&quot; &quot;</span> <span style="color: pink;">+</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;Last Name&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">elseif</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;First Name&quot;</span> <span style="color: #FF0000;">-and</span> <span style="color: pink;">!</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;Last Name&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.NickName <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;First Name&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">elseif</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;First Name&quot;</span> <span style="color: #FF0000;">-and</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;Last Name&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.NickName <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800000;">&quot;Last Name&quot;</span>;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.DisplayName <span style="color: pink;">=</span> <span style="color: #800080;">$ExchangeContact</span>.NickName;<br />
&nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.FileAs <span style="color: pink;">=</span> <span style="color: #800080;">$ExchangeContact</span>.NickName;<br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; <span style="color: #800080;">$BusinessPhysicalAddressEntry</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.PhysicalAddressEntry;<br />
&nbsp; &nbsp; <span style="color: #800080;">$HomePhysicalAddressEntry</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.PhysicalAddressEntry;<br />
&nbsp; &nbsp; <span style="color: #800080;">$OtherPhysicalAddressEntry</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Microsoft.Exchange.WebServices.Data.PhysicalAddressEntry;<br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; <span style="color: #008000;"># This uses the Contact Mapping above to save coding each and every field, one by one. Instead we look for a mapping and perform an action on</span><br />
&nbsp; &nbsp; <span style="color: #008000;"># what maps across. As some methods need more &quot;code&quot; a fake multi-dimensional array (seperated by :'s) is used where needed.</span><br />
&nbsp; &nbsp; <span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Key</span> <span style="color: #0000FF;">in</span> <span style="color: #800080;">$ContactMapping</span>.Keys<span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;"># Only do something if the key exists</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;"># Will this call a more complicated mapping?</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactMapping</span><span style="color: #000000;">&#91;</span><span style="color: #800080;">$Key</span><span style="color: #000000;">&#93;</span> <span style="color: #FF0000;">-like</span> <span style="color: #800000;">&quot;*:*&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;"># Make an array using the : to split items.</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$MappingArray</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactMapping</span><span style="color: #000000;">&#91;</span><span style="color: #800080;">$Key</span><span style="color: #000000;">&#93;</span>.Split<span style="color: #000000;">&#40;</span><span style="color: #800000;">&quot;:&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;"># Do action</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">switch</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">0</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Email&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.EmailAddresses<span style="color: #000000;">&#91;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.EmailAddressKey<span style="color: #000000;">&#93;</span>::<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#93;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Phone&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.PhoneNumbers<span style="color: #000000;">&#91;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.PhoneNumberKey<span style="color: #000000;">&#93;</span>::<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#93;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Address&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">switch</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Business&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$BusinessPhysicalAddressEntry</span>.<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">2</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.PhysicalAddresses<span style="color: #000000;">&#91;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.PhysicalAddressKey<span style="color: #000000;">&#93;</span>::<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#93;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$BusinessPhysicalAddressEntry</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Home&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$HomePhysicalAddressEntry</span>.<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">2</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.PhysicalAddresses<span style="color: #000000;">&#91;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.PhysicalAddressKey<span style="color: #000000;">&#93;</span>::<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#93;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$HomePhysicalAddressEntry</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Other&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$OtherPhysicalAddressEntry</span>.<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">2</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.PhysicalAddresses<span style="color: #000000;">&#91;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.PhysicalAddressKey<span style="color: #000000;">&#93;</span>::<span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#93;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$OtherPhysicalAddressEntry</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;Method&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">switch</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$MappingArray</span><span style="color: #000000;">&#91;</span><span style="color: #804000;">1</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800000;">&quot;SetContactPicture&quot;</span> <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$Exchange2007</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span><span style="color: #008080; font-weight: bold;">Get-Item</span> <span style="color: #008080; font-style: italic;">-Path</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Contact Picture File not found at $($ContactItem.$Key)&quot;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.SetContactPicture<span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">else</span> <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #008000;"># It's a direct mapping - simple!</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactMapping</span><span style="color: #000000;">&#91;</span><span style="color: #800080;">$Key</span><span style="color: #000000;">&#93;</span> <span style="color: #FF0000;">-eq</span> <span style="color: #800000;">&quot;Birthday&quot;</span> <span style="color: #FF0000;">-or</span> <span style="color: #800080;">$ContactMapping</span><span style="color: #000000;">&#91;</span><span style="color: #800080;">$Key</span><span style="color: #000000;">&#93;</span> <span style="color: #FF0000;">-eq</span> <span style="color: #800000;">&quot;WeddingAnniversary&quot;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#91;</span>System.DateTime<span style="color: #000000;">&#93;</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">Get-Date</span><span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.<span style="color: #000000;">&#40;</span><span style="color: #800080;">$ContactMapping</span><span style="color: #000000;">&#91;</span><span style="color: #800080;">$Key</span><span style="color: #000000;">&#93;</span><span style="color: #000000;">&#41;</span> <span style="color: pink;">=</span> <span style="color: #800080;">$ContactItem</span>.<span style="color: #800080;">$Key</span>; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#125;</span> &nbsp; &nbsp;<br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; <span style="color: #008000;"># Save the contact &nbsp; &nbsp;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$ExchangeContact</span>.Save<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span>;<br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; <span style="color: #008000;"># Provide output that can be used on the pipeline</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$Output_Object</span> <span style="color: pink;">=</span> <span style="color: #008080; font-weight: bold;">New-Object</span> Object;<br />
&nbsp; &nbsp; <span style="color: #800080;">$Output_Object</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Add-Member</span> NoteProperty FileAs <span style="color: #800080;">$ExchangeContact</span>.FileAs;<br />
&nbsp; &nbsp; <span style="color: #800080;">$Output_Object</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Add-Member</span> NoteProperty GivenName <span style="color: #800080;">$ExchangeContact</span>.GivenName;<br />
&nbsp; &nbsp; <span style="color: #800080;">$Output_Object</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Add-Member</span> NoteProperty Surname <span style="color: #800080;">$ExchangeContact</span>.Surname;<br />
&nbsp; &nbsp; <span style="color: #800080;">$Output_Object</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Add-Member</span> NoteProperty EmailAddress1 <span style="color: #800080;">$ExchangeContact</span>.EmailAddresses<span style="color: #000000;">&#91;</span><span style="color: #000000;">&#91;</span>Microsoft.Exchange.WebServices.Data.EmailAddressKey<span style="color: #000000;">&#93;</span>::EmailAddress1<span style="color: #000000;">&#93;</span><br />
&nbsp; &nbsp; <span style="color: #800080;">$Output_Object</span>;<br />
<span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p><a href="http://www.stevieg.org/downloads/Import-MailboxContacts.zip"><strong>Download as ZIP</strong></a></p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/5SRC_RzIB5FpQ7Xlb2VsVMSxghs/0/da"><img src="http://feedads.g.doubleclick.net/~a/5SRC_RzIB5FpQ7Xlb2VsVMSxghs/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/5SRC_RzIB5FpQ7Xlb2VsVMSxghs/1/da"><img src="http://feedads.g.doubleclick.net/~a/5SRC_RzIB5FpQ7Xlb2VsVMSxghs/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/iYNferLmvrk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/07/using-powershell-to-import-contacts-into-exchange-and-outlook-live/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Using the Exchange 2010 SP1 Mailbox Export features for Mass Exports to PST files</title>
		<link>http://www.stevieg.org/2010/07/using-the-exchange-2010-sp1-mailbox-export-features-for-mass-exports-to-pst/</link>
		<comments>http://www.stevieg.org/2010/07/using-the-exchange-2010-sp1-mailbox-export-features-for-mass-exports-to-pst/#comments</comments>
		<pubDate>Sat, 17 Jul 2010 20:26:09 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Walkthroughs]]></category>
		<category><![CDATA[Exchange2010]]></category>
		<category><![CDATA[exchangeserver2010]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=307</guid>
		<description><![CDATA[In Exchange 2007 SP1 thru to Exchange 2010 RTM, the Export-Mailbox command was the replacement for the once-familiar ExMerge utility when it came to exporting mailboxes to PST files.
The main problem with Export-Mailbox for most Exchange administrators is the requirement for Outlook – either on a 32-bit machine with Management Tools for Exchange 2007, or [...]]]></description>
			<content:encoded><![CDATA[<p>In Exchange 2007 SP1 thru to Exchange 2010 RTM, the Export-Mailbox command was the replacement for the once-familiar <a href="http://www.microsoft.com/downloads/details.aspx?familyid=429163ec-dcdf-47dc-96da-1c12d67327d5&amp;displaylang=en" target="_blank">ExMerge</a> utility when it came to exporting mailboxes to PST files.</p>
<p>The main problem with Export-Mailbox for most Exchange administrators is the requirement for Outlook – either on a 32-bit machine with Management Tools for Exchange 2007, or on a 64-bit machine for Exchange 2010. All in all, it wasn’t ideal and certainly didn’t facilitate scripted mailbox exports.</p>
<p>Thankfully, with Exchange 2010 SP1, Export-Mailbox is going the way of the dodo and new cmdlets for Mailbox imports and exports are available. Just like the New-MoveRequest cmdlet, the new import/export command use the <a href="http://technet.microsoft.com/en-us/library/dd298174.aspx#MRS" target="_blank">Mailbox Replication Service</a> to perform the move via one of the Client Access Servers giving performance benefits, such as ensuring the PST transfer doesn’t have to go via the machine with the Exchange Management Tools/Outlook installed, as was the case previously.</p>
<p>The main aim of this post is to give you an overview of how to use the new mailbox export cmdlets, and then show you how to put them to practical use, both at the command line and with a scheduled task for brick-level backups.</p>
<h5>Getting it set up</h5>
<p>The basic requirements for using the new feature are pretty straightforward. You need to use an account that’s a member of the organisational management groups, and have the “Mailbox Import Export” role assignment assigned to you or a role group you’re a member of. As the export is done at a CAS server (and if you’ve multiple CAS servers you can’t specify which one in each site will be used) you can’t specify a local drive letter and path – you must specify a UNC path to a network share that the “Exchange Trusted Subsystem” group has read/write access to.</p>
<h6>Step One</h6>
<p>Create a share on a server, and grant <strong>Exchange Trusted Subsystem</strong> read/write permission. In this example I’m using a share called <strong>Exports</strong> on a test server called <strong>Azua</strong> in my lab environment:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image56.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image5_thumb.png" border="0" alt="image" width="226" height="287" /></a></p>
<h6>Step Two</h6>
<p>Next, you’ll need to grant a user, or group, the <strong>Mailbox Import Export</strong> role assignment. You can do this using the Exchange Management shell with a single command. In this example, I’m granting my lab domain’s Administrator user the role assignment:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image111.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image11_thumb.png" border="0" alt="image" width="714" height="87" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">New<span style="color: pink;">-</span>ManagementRoleAssignment –Role “Mailbox Import Export” –User AD\Administrator</div></div>
<p>After you’ve done this, close and re-open the Exchange Management shell, and you’re ready to go!</p>
<h5>Exporting a Mailbox</h5>
<p>At it’s simplest, use the <strong>New-MailboxExportRequest</strong> command with the –<strong>Mailbox</strong> parameter, to specify the mailbox to export along with the –<strong>FilePath</strong> parameter, to specify the PST file to create and export data to, e.g:</p>
<h5><a href="http://www.stevieg.org/wp-content/uploads/image57.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb38.png" border="0" alt="image" width="714" height="66" /></a></h5>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">New<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>Mailbox Administrator <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;\\AZUA\Exports\Administrator.pst&quot;</span></div></div>
<p>In addition, there are some other useful options – such as –<strong>BatchName</strong>, which allows grouping of requests together, and –<strong>ContentFilter</strong>, which allows only certain content to be exported to the PST – useful for discovery purposes.  As usual, use the <strong>Get-Help New-MailboxExportRequest –detailed</strong> command to review the full plethora of options.</p>
<p>After submission of your requests, you can check progress, including the percentage complete, with the two <strong>Get-MailboxExportRequest </strong>and the <strong>Get-MailboxExportRequestStatistics</strong> commands. Pipe the former into the latter to get a listing:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image58.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb39.png" border="0" alt="image" width="714" height="66" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">|</span> Get<span style="color: pink;">-</span>MailboxExportRequestStatistics</div></div>
<p>After the requests complete, you can remove the requests in a similar fashion, using the <strong>Remove-MailboxExportRequest</strong> command:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image59.png"><img style="display: inline; border-width: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb40.png" border="0" alt="image" width="714" height="90" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">Get<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">|</span> Remove<span style="color: pink;">-</span>MailboxExportRequest</div></div>
<h5>Performing mass exports</h5>
<p>One benefit of Powershell is it’s very easy to put together commands enabling mass-exports of PST data with only a few commands. If you really wanted to, you could even use a Powershell script as a secondary brick-level backup!</p>
<h6>The Basics</h6>
<p>So to check out how to do this, let’s look at it’s simplest – backing up all the mailboxes (assuming it’s a full Exchange 2010 environment) to a single share:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image61.png"><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb42.png" border="0" alt="image" width="718" height="31" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$i</span> <span style="color: #0000FF;">in</span> <span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>Mailbox<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#123;</span> New<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>Mailbox <span style="color: #800080;">$i</span> <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;\\AZUA\Exports\${$i.Alias).pst&quot;</span> <span style="color: #000000;">&#125;</span></div></div>
<p>In the above example, we’re simply performing a for-each loop through each mailbox and creating a new Mailbox Export Request, using the alias to build the name for the PST.</p>
<p>But – what if we’re in a mixed environment, and only want to target the Exchange 2010 mailboxes?</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image62.png"><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb43.png" border="0" alt="image" width="718" height="87" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$i</span> <span style="color: #0000FF;">in</span> <span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>Mailbox <span style="color: pink;">|</span> <span style="color: #0000FF;">Where</span> <span style="color: #000000;">&#123;</span><a href="about:blank"><span style="color: #000080;">$_</span></a>.ExchangeVersion.ExchangeBuild.Major <span style="color: #FF0000;">-eq</span> <span style="color: #804000;">14</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#123;</span> New<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>Mailbox <span style="color: #800080;">$i</span> <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;\\AZUA\Exports\${$i.Alias).pst&quot;</span> <span style="color: #000000;">&#125;</span></div></div>
<p>In this example above, now, we’ve added a clause to only select the mailboxes where the Exchange Major Build is 14 – Exchange 2010. Simple!</p>
<p>Moving on from such wide-targeting, you may want to target just a pre-defined list, using a CSV file. To do this, simply create a CSV file with the column “Alias”, and list the Mailbox alias fields you wish to export. Then, using the Import-CSV command we can use this CSV file to create the requests:</p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image63.png"><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb44.png" border="0" alt="image" width="718" height="78" /></a></p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$i</span> <span style="color: #0000FF;">in</span> <span style="color: #000000;">&#40;</span><span style="color: #008080; font-weight: bold;">Import-Csv</span> .\exports.csv<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#123;</span> New<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>Mailbox <span style="color: #800080;">$i</span>.Alias <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;\\AZUA\Exports\$($i.Alias).pst&quot;</span> <span style="color: #000000;">&#125;</span></div></div>
<h6>Performing Mass Exports as a scheduled task</h6>
<p>Now you’ve seen the basics of how easy it is to perform mass mailbox exports using the New-MailboxExportRequest command, I’ll finish off with a final example showing how to use this mass export feature as part of a scheduled task.</p>
<p>This script is aimed at backing up all the mailboxes on a single database, or a single server. After creating the requests, it waits for the requests to complete then, if you’ve specified a report directory, it will write reports showing completed and incomplete (i.e. failed!) requests. Finally it removes the requests it created.</p>
<p>To use the script, you need to alter the config section and specify either a server or a database, a share to export to, a share to write a report to after the process has completed and you can choose whether to remove each mailbox’s associated PST file or leave as-is at each export – merging the contents.</p>
<p>You’ll see the content of the script below and at the bottom of the post I’ve zipped it up along with a bootstrap CMD file you could use when setting up a schedule task. As always – use at your own risk and test out in your lab environment first. Happy Exporting!</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;height:400px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #008000;"># Exchange 2010 SP1 Mailbox Export Script</span><br />
<span style="color: #008000;"># Steve Goodman. Use at your own risk!</span><br />
<br />
<span style="color: #008000;">###############</span><br />
<span style="color: #008000;"># Settings &nbsp; &nbsp;#</span><br />
<span style="color: #008000;">###############</span><br />
<br />
<span style="color: #008000;"># Pick ONE of the two below. If you choose both, it will use $Server.</span><br />
<span style="color: #800080;">$Server</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;server&quot;</span><br />
<span style="color: #800080;">$Database</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;&quot;</span><br />
<br />
<span style="color: #008000;"># Share to export mailboxes to. Needs R/W by Exchange Trusted Subsystem</span><br />
<span style="color: #008000;"># Must be a UNC path as this is run by the CAS MRS service.</span><br />
<span style="color: #800080;">$ExportShare</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;\\server\share&quot;</span><br />
<br />
<span style="color: #008000;"># After each run a report of the exports can be dropped into the directory specified below. (The user that runs this script needs access to this share)</span><br />
<span style="color: #008000;"># Must be a UNC path or the full path of a local directory.</span><br />
<span style="color: #800080;">$ReportShare</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;\\server\share&quot;</span><br />
<br />
<span style="color: #008000;"># Shall we remove the PST file, if it exists beforehand? (The user that runs this script needs access to the $ExportShare share)</span><br />
<span style="color: #008000;"># Valid values: $true or $false</span><br />
<span style="color: #800080;">$RemovePSTBeforeExport</span> <span style="color: pink;">=</span> <span style="color: #800080;">$false</span><br />
<br />
<span style="color: #008000;">###############</span><br />
<span style="color: #008000;"># Code &nbsp; &nbsp; &nbsp; &nbsp;#</span><br />
<span style="color: #008000;">###############</span><br />
<br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Server</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>ExchangeServer <span style="color: #800080;">$Server</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Exchange Server $Server not found&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>MailboxDatabase <span style="color: pink;">-</span>Server <span style="color: #800080;">$Server</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Exchange Server $Server does not have mailbox databases&quot;</span>;<br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #800080;">$Mailboxes</span> <span style="color: pink;">=</span> Get<span style="color: pink;">-</span>Mailbox <span style="color: pink;">-</span>Server <span style="color: #800080;">$Server</span> <span style="color: pink;">-</span>ResultSize Unlimited<br />
<span style="color: #000000;">&#125;</span> <span style="color: #0000FF;">elseif</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Database</span><span style="color: #000000;">&#41;</span> <span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>MailboxDatabase <span style="color: #800080;">$Database</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;Mailbox database $Database not found&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #800080;">$Mailboxes</span> <span style="color: pink;">=</span> Get<span style="color: pink;">-</span>Mailbox <span style="color: pink;">-</span>Database <span style="color: #800080;">$Database</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$Mailboxes</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;No mailboxes found on $Server&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: pink;">!</span><span style="color: #800080;">$Mailboxes</span>.Count<span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #0000FF;">throw</span> <span style="color: #800000;">&quot;This script does not support a single mailbox export.&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Pre-checks done</span><br />
<br />
<span style="color: #008000;"># Make batch name</span><br />
<span style="color: #800080;">$date</span><span style="color: pink;">=</span><span style="color: #008080; font-weight: bold;">Get-Date</span><br />
<span style="color: #800080;">$BatchName</span> <span style="color: pink;">=</span> <span style="color: #800000;">&quot;Export_$($date.Year)-$($date.Month)-$($date.Day)_$($date.Hour)-$($date.Minute)-$($date.Second)&quot;</span><br />
<br />
<span style="color: #008080; font-weight: bold;">Write-Output</span> <span style="color: #800000;">&quot;Queuing $($Mailboxes.Count) mailboxes as batch '$($BatchName)'&quot;</span><br />
<br />
<span style="color: #008000;"># Queue all mailbox export requests</span><br />
<span style="color: #0000FF;">foreach</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Mailbox</span> <span style="color: #0000FF;">in</span> <span style="color: #800080;">$Mailboxes</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$RemovePSTBeforeExport</span> <span style="color: #FF0000;">-eq</span> <span style="color: #800080;">$true</span> <span style="color: #FF0000;">-and</span> <span style="color: #000000;">&#40;</span><span style="color: #008080; font-weight: bold;">Get-Item</span> <span style="color: #800000;">&quot;$($ExportShare)\$($Mailbox.Alias).PST&quot;</span> <span style="color: #008080; font-style: italic;">-ErrorAction</span> SilentlyContinue<span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #008080; font-weight: bold;">Remove-Item</span> <span style="color: #800000;">&quot;$($ExportShare)\$($Mailbox.Alias).PST&quot;</span> <span style="color: #008080; font-style: italic;">-Confirm</span>:<span style="color: #800080;">$false</span><br />
<span style="color: #000000;">&#125;</span><br />
New<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>BatchName <span style="color: #800080;">$BatchName</span> <span style="color: pink;">-</span>Mailbox <span style="color: #800080;">$Mailbox</span>.Alias <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;$($ExportShare)\$($Mailbox.Alias).PST&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008080; font-weight: bold;">Write-Output</span> <span style="color: #800000;">&quot;Waiting for batch to complete&quot;</span><br />
<br />
<span style="color: #008000;"># Wait for mailbox export requests to complete</span><br />
<span style="color: #0000FF;">while</span> <span style="color: #000000;">&#40;</span><span style="color: #000000;">&#40;</span>Get<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>BatchName <span style="color: #800080;">$BatchName</span> <span style="color: pink;">|</span> <span style="color: #0000FF;">Where</span> <span style="color: #000000;">&#123;</span><a href="about:blank"><span style="color: #000080;">$_</span></a>.Status <span style="color: #FF0000;">-eq</span> <span style="color: #800000;">&quot;Queued&quot;</span> <span style="color: #FF0000;">-or</span> <a href="about:blank"><span style="color: #000080;">$_</span></a>.Status <span style="color: #FF0000;">-eq</span> <span style="color: #800000;">&quot;InProgress&quot;</span><span style="color: #000000;">&#125;</span><span style="color: #000000;">&#41;</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<br />
<span style="color: #008080; font-weight: bold;">sleep</span> <span style="color: #804000;">60</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Write reports if required</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$ReportShare</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #008080; font-weight: bold;">Write-Output</span> <span style="color: #800000;">&quot;Writing reports to $($ReportShare)&quot;</span><br />
<span style="color: #800080;">$Completed</span> <span style="color: pink;">=</span> Get<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>BatchName <span style="color: #800080;">$BatchName</span> <span style="color: pink;">|</span> <span style="color: #0000FF;">Where</span> <span style="color: #000000;">&#123;</span><a href="about:blank"><span style="color: #000080;">$_</span></a>.Status <span style="color: #FF0000;">-eq</span> <span style="color: #800000;">&quot;Completed&quot;</span><span style="color: #000000;">&#125;</span> <span style="color: pink;">|</span> Get<span style="color: pink;">-</span>MailboxExportRequestStatistics <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Format-List</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Completed</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #800080;">$Completed</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Out<span style="color: #FF0000;">-File</span></span> <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;$($ReportShare)\$($BatchName)_Completed.txt&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #800080;">$Incomplete</span> <span style="color: pink;">=</span> Get<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>BatchName <span style="color: #800080;">$BatchName</span> <span style="color: pink;">|</span> <span style="color: #0000FF;">Where</span> <span style="color: #000000;">&#123;</span><a href="about:blank"><span style="color: #000080;">$_</span></a>.Status <span style="color: #FF0000;">-ne</span> <span style="color: #800000;">&quot;Completed&quot;</span><span style="color: #000000;">&#125;</span> <span style="color: pink;">|</span> Get<span style="color: pink;">-</span>MailboxExportRequestStatistics <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Format-List</span><br />
<span style="color: #0000FF;">if</span> <span style="color: #000000;">&#40;</span><span style="color: #800080;">$Incomplete</span><span style="color: #000000;">&#41;</span><br />
<span style="color: #000000;">&#123;</span><br />
<span style="color: #800080;">$Incomplete</span> <span style="color: pink;">|</span> <span style="color: #008080; font-weight: bold;">Out<span style="color: #FF0000;">-File</span></span> <span style="color: #008080; font-style: italic;">-FilePath</span> <span style="color: #800000;">&quot;$($ReportShare)\$($BatchName)_Incomplete_Report.txt&quot;</span><br />
<span style="color: #000000;">&#125;</span><br />
<span style="color: #000000;">&#125;</span><br />
<br />
<span style="color: #008000;"># Remove Requests</span><br />
<span style="color: #008080; font-weight: bold;">Write-Output</span> <span style="color: #800000;">&quot;Removing requests created as part of batch '$($BatchName)'&quot;</span><br />
Get<span style="color: pink;">-</span>MailboxExportRequest <span style="color: pink;">-</span>BatchName <span style="color: #800080;">$BatchName</span> <span style="color: pink;">|</span> Remove<span style="color: pink;">-</span>MailboxExportRequest <span style="color: #008080; font-style: italic;">-Confirm</span>:$false</div></div>
<p>Command file contents:</p>
<div class="codecolorer-container powershell default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="powershell codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe <span style="color: #008080; font-style: italic;">-command</span> <span style="color: #800000;">&quot;. 'c:\Program Files\Microsoft\Exchange Server\V14\bin\RemoteExchange.ps1'; Connect-ExchangeServer -auto; .\MassExport.ps1&quot;</span></div></div>
<p><strong><a href="http://www.stevieg.org/downloads/MassExport.zip" target="_blank">Download as ZIP</a></strong></p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/E8sbcnEguFUWIJhZR_Sv0RfzIjs/0/da"><img src="http://feedads.g.doubleclick.net/~a/E8sbcnEguFUWIJhZR_Sv0RfzIjs/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/E8sbcnEguFUWIJhZR_Sv0RfzIjs/1/da"><img src="http://feedads.g.doubleclick.net/~a/E8sbcnEguFUWIJhZR_Sv0RfzIjs/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/jLQ8gAMbbLo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/07/using-the-exchange-2010-sp1-mailbox-export-features-for-mass-exports-to-pst/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>New OWA themes available in Exchange 2010 SP1</title>
		<link>http://www.stevieg.org/2010/07/new-themes-available-in-exchange-2010-sp1/</link>
		<comments>http://www.stevieg.org/2010/07/new-themes-available-in-exchange-2010-sp1/#comments</comments>
		<pubDate>Sat, 17 Jul 2010 19:48:01 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Exchange2010]]></category>
		<category><![CDATA[exchangeserver2010]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=289</guid>
		<description><![CDATA[In my earlier post about the Outlook Web App improvements in SP1 you’d have seen than in Exchange 2010 SP1, themes are making a welcome return.
If you don’t have the resources and time to install the SP1 beta yourself, or just want a quick look at all the new themes that will be included in [...]]]></description>
			<content:encoded><![CDATA[<p>In my earlier post about <a href="http://www.stevieg.org/2010/04/a-quick-look-at-outlook-web-app-improvements-coming-in-exchange-2010-sp1/" target="_blank">the Outlook Web App improvements in SP1</a> you’d have seen than in Exchange 2010 SP1, themes are making a welcome return.</p>
<p>If you don’t have the resources and time to install the SP1 beta yourself, or just want a quick look at all the new themes that will be included in the upcoming service pack, this quick post is for you!</p>
<p><strong>Default</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image34.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb17.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Mixxer</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image35.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb18.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Botanical</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image36.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb19.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>One World</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image37.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb20.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Super Sparkle Happy</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image38.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb21.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>It Came From Space</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image39.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb22.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Autumn Blade</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image41.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb23.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Herding Cats</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image42.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb24.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Finger Paints</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image43.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb25.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Damask</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image44.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb26.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Arctic</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image45.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb27.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Cupcake</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image46.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb28.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Blibbet</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image47.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb29.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Gothitech</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image48.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb30.png" border="0" alt="image" width="674" height="85" /></strong></a><strong> </strong></p>
<p><strong>Winterland</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image49.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb31.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Pink</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image50.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb32.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Blue</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image51.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb33.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Green</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image52.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb34.png" border="0" alt="image" width="674" height="82" /></strong></a><strong> </strong></p>
<p><strong>Voilet</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image53.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb35.png" border="0" alt="image" width="674" height="79" /></strong></a><strong> </strong></p>
<p><strong>Grey</strong></p>
<p><a href="http://www.stevieg.org/wp-content/uploads/image54.png"><strong><img style="display: inline; border: 0px;" title="image" src="http://www.stevieg.org/wp-content/uploads/image_thumb36.png" border="0" alt="image" width="674" height="79" /></strong></a></p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/0_JyVZhl7xQkKoLi9Fvy5zxnCX0/0/da"><img src="http://feedads.g.doubleclick.net/~a/0_JyVZhl7xQkKoLi9Fvy5zxnCX0/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/0_JyVZhl7xQkKoLi9Fvy5zxnCX0/1/da"><img src="http://feedads.g.doubleclick.net/~a/0_JyVZhl7xQkKoLi9Fvy5zxnCX0/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/ZcYeu8HRz7k" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/07/new-themes-available-in-exchange-2010-sp1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Useful articles from around the web in July…</title>
		<link>http://www.stevieg.org/2010/07/links-for-2010-07-15/</link>
		<comments>http://www.stevieg.org/2010/07/links-for-2010-07-15/#comments</comments>
		<pubDate>Thu, 15 Jul 2010 23:10:15 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[DeliciousLinks]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/2010/07/links-for-2010-07-15/</guid>
		<description><![CDATA[[Updated] - I've recompiled my link list for July and will continue to update it as anything I've found useful surfaces. These were originally published through Delicious.

The EXPTA {blog}: Trouble with ActiveSync with iOS4 for iPhone
The Cat Is Out Of The Bag. vSphere 4.1 &#124; Tech Blog
Manage Exchange 2007 Out-Of-Office (OOF) Settings with PowerShell and [...]]]></description>
			<content:encoded><![CDATA[<div>[Updated] - I've recompiled my link list for July and will continue to update it as anything I've found useful surfaces. These were originally published through Delicious.</div>
<div></div>
<div><a href="http://kendrickcoleman.com/index.php?/Tech-Blog/the-cats-out-of-the-bag-vsphere-41.html">The EXPTA {blog}: Trouble with ActiveSync with iOS4 for iPhone</a></div>
<div><a href="http://kendrickcoleman.com/index.php?/Tech-Blog/the-cats-out-of-the-bag-vsphere-41.html">The Cat Is Out Of The Bag. vSphere 4.1 | Tech Blog</a></div>
<div><a href="http://www.mikepfeiffer.net/2010/07/manage-exchange-2007-out-of-office-oof-settings-with-powershell-and-the-ews-managed-api/">Manage Exchange 2007 Out-Of-Office (OOF) Settings with PowerShell and the EWS Managed API</a></div>
<div><a href="http://www.nitrodesk.com/default.aspx">Touchdown, a decent Activesync client for Android Phones</a></div>
<div><a href="http://www.amazon.com/dp/0735627193">New Book: Microsoft Exchange Server 2010 Best Practices (covering SP1) by Siegfried Jagott &amp; Joel Stidley</a></div>
<div><a href="http://janssenjones.typepad.com/janssenjonescom/2009/10/powershell-iphone-prowl-sysadmin-notification-nirvana.html">JanssenJones.com: PowerShell + iPhone + Prowl = SysAdmin notification nirvana</a><a href="http://www.shudnow.net/2010/06/30/exchange-2010-database-activation-coordination-dac/"><br />
Exchange 2010 Database Activation Coordination (DAC) | Elan Shudnow's Blog</a><a href="http://blogs.technet.com/b/ilvancri/archive/2010/07/09/configuring-ad-rms-and-exchange-2010-sp1-beta.aspx"></a></div>
<div><a href="http://blogs.technet.com/b/ilvancri/archive/2010/07/09/configuring-ad-rms-and-exchange-2010-sp1-beta.aspx">Configuring AD RMS and Exchange 2010 Sp1 Beta - Ilse Van Criekinge's Weblog - Site Home - TechNet Blogs</a><a href="http://blogs.technet.com/b/provtest/archive/2010/07/05/what-s-not-available-in-exchange-2010-sp1-hosting-mode.aspx"></a></div>
<div><a href="http://blogs.technet.com/b/provtest/archive/2010/07/05/what-s-not-available-in-exchange-2010-sp1-hosting-mode.aspx">What's not available in Exchange 2010 SP1 Hosting Mode - TechNet Blogs</a><a href="http://searchexchange.techtarget.com/generic/0,295582,sid43_gci1516122,00.html"></a></div>
<div><a href="http://searchexchange.techtarget.com/generic/0,295582,sid43_gci1516122,00.html">Exchange 2010 SP1 personal archives -- Why you should wait</a><a href="http://blogs.msexchange.org/walther/2010/06/16/teched-2010-interviews-with-folks-from-the-exchange-product-group/"></a></div>
<div><a href="http://blogs.msexchange.org/walther/2010/06/16/teched-2010-interviews-with-folks-from-the-exchange-product-group/">Henrik Walther Blog » Blog Archive » TechEd 2010 Interviews with folks from the Exchange Product group</a></div>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/CnFI38RxQQsTUtxxtUh6zMuUdPM/0/da"><img src="http://feedads.g.doubleclick.net/~a/CnFI38RxQQsTUtxxtUh6zMuUdPM/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/CnFI38RxQQsTUtxxtUh6zMuUdPM/1/da"><img src="http://feedads.g.doubleclick.net/~a/CnFI38RxQQsTUtxxtUh6zMuUdPM/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/mCpTGpydlwg" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/07/links-for-2010-07-15/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Exchange 2010 SP1 posts from around the web in June..</title>
		<link>http://www.stevieg.org/2010/06/exchange-2010-sp1-posts-from-around-the-web-this-week/</link>
		<comments>http://www.stevieg.org/2010/06/exchange-2010-sp1-posts-from-around-the-web-this-week/#comments</comments>
		<pubDate>Thu, 10 Jun 2010 18:57:35 +0000</pubDate>
		<dc:creator>Steve Goodman</dc:creator>
				<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Exchange 2010 SP1]]></category>
		<category><![CDATA[Exchange2010]]></category>
		<category><![CDATA[exchangeserver2010]]></category>

		<guid isPermaLink="false">http://www.stevieg.org/?p=216</guid>
		<description><![CDATA[With the release to the public of Exchange 2010 SP1 Beta, it's nice to see the everyone getting their hands dirty with it at long last. Here's a quick post with a few links I've seen and liked over the last few days.
Installing Exchange 2010 SP1 Beta (Mike Crowley's Whiteboard)
RBAC Database Scopes in Exchange Server [...]]]></description>
			<content:encoded><![CDATA[<p>With the release to the public of Exchange 2010 SP1 Beta, it's nice to see the everyone getting their hands dirty with it at long last. Here's a quick post with a few links I've seen and liked over the last few days.</p>
<p><a href="http://mikecrowley.wordpress.com/2010/06/07/installing-exchange-2010-sp1-beta-2/">Installing Exchange 2010 SP1 Beta</a> (Mike Crowley's Whiteboard)</p>
<p><a href="http://www.mikepfeiffer.net/2010/06/rbac-database-scopes-in-exchange-server-2010-sp1-beta/">RBAC Database Scopes in Exchange Server 2010 SP1 Beta</a> (Mike Pfeiffer's Blog)</p>
<p><a href="http://www.howexchangeworks.com/2010/06/installing-exchange-2010-pre-requisites.html">Installing Exchange 2010 Pre-requisites Made Part Of The SP1 Beta Setup Process…</a> (How Exchange Works)</p>
<p><a href="http://www.howexchangeworks.com/2010/06/archive-mailbox-improvements-in.html?utm_source=feedburner&amp;utm_medium=twitter&amp;utm_campaign=Feed%3A+howexchangeworks+%28How+Exchange+Works%3F%29&amp;utm_content=Twitter">Archive Mailbox Improvements In Exchange 2010 SP1 Beta…</a> (How Exchange Works)</p>
<p>And of course there's a few more older articles linked at the <a href="http://social.technet.microsoft.com/wiki/contents/articles/exchange-2010-service-pack-1-overview.aspx">Technet Wiki</a></p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.stevieg.org/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>
<p><a href="http://feedads.g.doubleclick.net/~a/bQh55ZVDgLrucCypiqGU1awNNDA/0/da"><img src="http://feedads.g.doubleclick.net/~a/bQh55ZVDgLrucCypiqGU1awNNDA/0/di" border="0" ismap="true"></img></a><br/>
<a href="http://feedads.g.doubleclick.net/~a/bQh55ZVDgLrucCypiqGU1awNNDA/1/da"><img src="http://feedads.g.doubleclick.net/~a/bQh55ZVDgLrucCypiqGU1awNNDA/1/di" border="0" ismap="true"></img></a></p><img src="http://feeds.feedburner.com/~r/stevieg/~4/Dg886TE6fcg" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.stevieg.org/2010/06/exchange-2010-sp1-posts-from-around-the-web-this-week/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
