<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>sides of march</title>
	<atom:link href="http://www.sidesofmarch.com/index.php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.sidesofmarch.com</link>
	<description>Thoughts on life, liberty, and information technology</description>
	<lastBuildDate>Tue, 10 Apr 2012 14:12:45 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Dynamics CRM doesn&#8217;t enable search on Address ZIP/Postal Code by default</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2012/04/10/dynamics-crm-doesnt-enable-search-on-address-zippostal-code-by-default/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2012/04/10/dynamics-crm-doesnt-enable-search-on-address-zippostal-code-by-default/#comments</comments>
		<pubDate>Tue, 10 Apr 2012 14:12:45 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Dynamics CRM]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=622</guid>
		<description><![CDATA[<p>In the &#8220;oh my, how did that slip through?&#8221; category comes this one: in Dynamics CRM 2011, the ZIP/Postal Code field on the Address (CustomerAddress) entity is <em>not searchable by default</em>.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CRM-Address-ZIP-code-not-searchable-by-default.png"></a></p>
<p>Weirder is that the ZIP/Postal Code fields on the Account, Lead, and Contact entities <em>are searchable by default</em>. Weird only because they use the same underlying table (CustomerAddress).</p>
<p>Keep this in mind when you wonder why you can&#8217;t search for additional addresses by ZIP code. Make that ZIP/Postal Code field on the Address entity searchable, and you&#8217;re good <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2012/04/10/dynamics-crm-doesnt-enable-search-on-address-zippostal-code-by-default/">Dynamics CRM doesn&#8217;t enable search on Address ZIP/Postal Code by default</a></span>]]></description>
			<content:encoded><![CDATA[<p>In the &#8220;oh my, how did that slip through?&#8221; category comes this one: in Dynamics CRM 2011, the ZIP/Postal Code field on the Address (CustomerAddress) entity is <em>not searchable by default</em>.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CRM-Address-ZIP-code-not-searchable-by-default.png"><img class="size-full wp-image-623 alignnone" style="padding: 2px;" title="Dynamics CRM Address ZIP code not searchable by default" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CRM-Address-ZIP-code-not-searchable-by-default.png" alt="" width="814" height="170" /></a></p>
<p>Weirder is that the ZIP/Postal Code fields on the Account, Lead, and Contact entities <em>are searchable by default</em>. Weird only because they use the same underlying table (CustomerAddress).</p>
<p>Keep this in mind when you wonder why you can&#8217;t search for additional addresses by ZIP code. Make that ZIP/Postal Code field on the Address entity searchable, and you&#8217;re good to go.</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=622&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2012/04/10/dynamics-crm-doesnt-enable-search-on-address-zippostal-code-by-default/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Damn the documentation: FtpWebRequest.Timeout default value is NOT Infinite</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2012/04/06/damn-the-documentation-ftpwebrequest-timeout-default-value-is-not-infinite/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2012/04/06/damn-the-documentation-ftpwebrequest-timeout-default-value-is-not-infinite/#comments</comments>
		<pubDate>Fri, 06 Apr 2012 19:10:54 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[.Net]]></category>
		<category><![CDATA[FtpWebRequest]]></category>
		<category><![CDATA[MSDN]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=615</guid>
		<description><![CDATA[<p>For the past few weeks, an FTP upload has been failing, rather religiously, with the following .Net error:</p>
<blockquote><p>System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a receive.</p></blockquote>
<p>For the FTP upload, I was using the .Net FtpWebRequest class, in a rather simple code snippet:</p>


FtpWebRequest request = (FtpWebRequest)WebRequest.Create(config.Uri);
request.UsePassive = config.UsePassive;
request.Method = WebRequestMethods.Ftp.UploadFile;
request.Credentials = new NetworkCredential(config.UserName, config.Password);

<p>The FTP connection was dropping, but why? The transfer file was rather large (over 50MB), but reading the <a title="MSDN: FtpWebRequest.Timeout Property (System.Net)" href="http://msdn.microsoft.com/en-us/library/system.net.ftpwebrequest.timeout%28v=vs.100%29.aspx">MSDN documentation for the FtpWebRequest.Timeout property</a>, it was pretty clear that the .Net Framework wasn&#8217;t timing out, because:</p>
<blockquote>
FtpWebRequest.Timeout Property
<p>Type: <a href="http://msdn.microsoft.com/en-us/library/system.int32.aspx">System.Int32</a>
An <a href="http://msdn.microsoft.com/en-us/library/system.int32.aspx">Int32</a> value that contains the number of milliseconds to wait before a request times out. The default value is <a href="http://msdn.microsoft.com/en-us/library/system.threading.timeout.infinite.aspx">Infinite</a>.</p></blockquote>
<p>I tried active and passive connections; both failed. I checked the firewall; nothing unusual. I tried other external servers; they all failed. What gives?</p>
<p>Finally, exasperated, I tried forcing the timeout:</p>


FtpWebRequest request = (FtpWebRequest)WebRequest.Create(config.Uri);
request.UsePassive = config.UsePassive;
request.Method = WebRequestMethods.Ftp.UploadFile;
request.Credentials = new NetworkCredential(config.UserName, <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2012/04/06/damn-the-documentation-ftpwebrequest-timeout-default-value-is-not-infinite/">Damn the documentation: FtpWebRequest.Timeout default value is NOT Infinite</a></span>]]></description>
			<content:encoded><![CDATA[<p>For the past few weeks, an FTP upload has been failing, rather religiously, with the following .Net error:</p>
<blockquote><p>System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a receive.</p></blockquote>
<p>For the FTP upload, I was using the .Net <code>FtpWebRequest</code> class, in a rather simple code snippet:</p>
<pre class="brush: csharp; ">

FtpWebRequest request = (FtpWebRequest)WebRequest.Create(config.Uri);
request.UsePassive = config.UsePassive;
request.Method = WebRequestMethods.Ftp.UploadFile;
request.Credentials = new NetworkCredential(config.UserName, config.Password);
</pre>
<p>The FTP connection was dropping, but why? The transfer file was rather large (over 50MB), but reading the <a title="MSDN: FtpWebRequest.Timeout Property (System.Net)" href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fmsdn.microsoft.com%2Fen-us%2Flibrary%2Fsystem.net.ftpwebrequest.timeout%2528v%3Dvs.100%2529.aspx&sref=rss">MSDN documentation for the FtpWebRequest.Timeout property</a>, it was pretty clear that the .Net Framework wasn&#8217;t timing out, because:</p>
<blockquote>
<h3>FtpWebRequest.Timeout Property</h3>
<p>Type: <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fmsdn.microsoft.com%2Fen-us%2Flibrary%2Fsystem.int32.aspx&sref=rss">System.Int32</a><br />
An <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fmsdn.microsoft.com%2Fen-us%2Flibrary%2Fsystem.int32.aspx&sref=rss">Int32</a> value that contains the number of milliseconds to wait before a request times out. The default value is <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fmsdn.microsoft.com%2Fen-us%2Flibrary%2Fsystem.threading.timeout.infinite.aspx&sref=rss">Infinite</a>.</p></blockquote>
<p>I tried active and passive connections; both failed. I checked the firewall; nothing unusual. I tried other external servers; they all failed. What gives?</p>
<p>Finally, exasperated, I tried forcing the timeout:</p>
<pre class="brush: csharp; ">

FtpWebRequest request = (FtpWebRequest)WebRequest.Create(config.Uri);
request.UsePassive = config.UsePassive;
request.Method = WebRequestMethods.Ftp.UploadFile;
request.Credentials = new NetworkCredential(config.UserName, config.Password);
request.Timeout = -1;
</pre>
<p>Viola! The FTP upload did not fail! Stepping through the code, I found that, contrary to the documentation, the default value for FtpWebReqeust.Timeout is <em>not</em> infinite:</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/FtpWebRequest.Timeout.png"><img class="aligncenter size-full wp-image-616" title="FtpWebRequest.Timeout default values (Visual Studio Watch window)" src="http://www.sidesofmarch.com/wp-content/uploads/FtpWebRequest.Timeout.png" alt="" width="371" height="122" /></a>That is right, my friends: contrary to what you read in the documentation, the default value is 100,000 milliseconds, or about 1 minute, 40 seconds.</p>
<p>Lessons learned:</p>
<ol>
<li>Don&#8217;t believe everything you read.</li>
<li><a href="http://redirectingat.com?id=17923X751173&xs=1&url=https%3A%2F%2Fen.wikipedia.org%2Fwiki%2FTrust%2C_but_verify&sref=rss">Trust, but verify</a>.</li>
<li>Infinite is not infinite when it is not infinite.</li>
</ol>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=615&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2012/04/06/damn-the-documentation-ftpwebrequest-timeout-default-value-is-not-infinite/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>URL Rewriting for user-friendly URLs with Dynamics CRM 2011</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2012/01/15/url-rewriting-for-user-friendly-urls-with-dynamics-crm-2011/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2012/01/15/url-rewriting-for-user-friendly-urls-with-dynamics-crm-2011/#comments</comments>
		<pubDate>Mon, 16 Jan 2012 01:11:17 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Dynamics CRM]]></category>
		<category><![CDATA[IFD]]></category>
		<category><![CDATA[IIS]]></category>
		<category><![CDATA[URL Rewriting]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=601</guid>
		<description><![CDATA[<p>Anyone who has attempted to configure Dynamics CRM 2011 with an Internet-Facing Deployment (IFD) knows that it is no trivial task. Where there are <a href="http://www.interactivewebs.com/blog/index.php/server-tips/microsoft-crm-2011-how-to-configure-ifd-hosted-setup/">blog posts that discuss setting up an IFD</a>, and Microsoft documentation for <a href="http://technet.microsoft.com/library/gg188602.aspx">configuring the IFD</a>, they often assume that ADFS and Dynamics CRM are installed on the same server, and that there is only one Dynamics CRM front-end server. Unfortunately, real-world implementations don’t always follow that.</p>
<p>For example, take the following configuration:</p>

a Dynamics CRM front-end server on the internal network, providing services to internal clients
a Dynamics CRM front-end server in an Internet-facing zone, providing services to external clients
a separate ADFS server accessible to internal and external clients

<p>Dynamics CRM with IFD requires a combination of ADFS relaying party trusts and DNS configuration to get things working. One caveat with IFDs is that the internal and external host names for the Dynamics CRM front-end servers must be different because, externally, the host name includes the CRM organization name. <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2012/01/15/url-rewriting-for-user-friendly-urls-with-dynamics-crm-2011/">URL Rewriting for user-friendly URLs with Dynamics CRM 2011</a></span>]]></description>
			<content:encoded><![CDATA[<p>Anyone who has attempted to configure Dynamics CRM 2011 with an Internet-Facing Deployment (IFD) knows that it is no trivial task. Where there are <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.interactivewebs.com%2Fblog%2Findex.php%2Fserver-tips%2Fmicrosoft-crm-2011-how-to-configure-ifd-hosted-setup%2F&sref=rss">blog posts that discuss setting up an IFD</a>, and Microsoft documentation for <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Ftechnet.microsoft.com%2Flibrary%2Fgg188602.aspx&sref=rss">configuring the IFD</a>, they often assume that ADFS and Dynamics CRM are installed on the same server, and that there is only one Dynamics CRM front-end server. Unfortunately, real-world implementations don’t always follow that.</p>
<p>For example, take the following configuration:</p>
<ul>
<li>a Dynamics CRM front-end server on the internal network, providing services to internal clients</li>
<li>a Dynamics CRM front-end server in an Internet-facing zone, providing services to external clients</li>
<li>a separate ADFS server accessible to internal and external clients</li>
</ul>
<p>Dynamics CRM with IFD requires a combination of ADFS relaying party trusts and DNS configuration to get things working. One caveat with IFDs is that the internal and external host names for the Dynamics CRM front-end servers must be different because, externally, the host name includes the CRM organization name. Where, internally, you may have <a href="#">https://icrm.contoso.com/crm</a>, externally you would have <a href="#">https://crm.contoso.com</a>.</p>
<p>Let’s flesh out our sample implementation and requirements:</p>
<ul>
<li><em>icrm.contoso.com</em> is our internal Dynamics CRM front-end server, accessible only on the internal network</li>
<li><em>ecrm.contoso.com</em> is our external Dynamics CRM front-end server, accessible to our internal network and the public Internet</li>
<li><em>adfs.contoso.com</em> is our ADFS server, accessible to our internal network and the public Internet</li>
<li>We have two Dynamics CRM organizations: <em>CRM</em> and <em>CRM-Test</em>.</li>
<li>We want our internal and external (public Internet) clients to access CRM using the same URLs: <em>crm.contoso.com </em>and <em>crm-test.contoso.com</em>. In other words, we don&#8217;t want the two-URL problem outlined above.</li>
</ul>
<p>The last bit has nothing to do with Dynamics CRM: it is all done in IIS. Let me explain how.<span id="more-601"></span></p>
<h3>IFD Host Names and DNS Configuration</h3>
<p>In order to get Dynamics CRM configured for the IFD, your internal DNS and external DNS must be set as needed to allow internal and external clients to resolve to all Dynamics CRM and ADFS host names.</p>
<p>One poorly-documented part of the IFD setup is what the host names should point to in the <em>Internet Facing Deployment Configuration Wizard</em>. The Discovery Web Service Domain (something like <em>dev.contoso.com</em>)<em> </em>and the “external domain where your Internet-facing servers are located” (something like <em>auth.contoso.com</em>) must both resolve to a Dynamics CRM front-end server, <em>not</em> the ADFS server. Be sure to set up these host names to resolve to your internal/external Dynamics CRM servers.</p>
<p>So, in our sample environment, our internal and external DNS has the following entries:</p>
<ul>
<li><em>contoso.com</em> zone:
<ul>
<li><em>icrm</em> (internal DNS only)</li>
<li><em>ecrm</em> (internal and external DNS)</li>
<li><em>adfs</em> (internal and external DNS)</li>
<li><em>auth</em> (internal and external DNS, points to <em>icrm</em> internally and <em>ecrm </em>externally)</li>
<li><em>dev</em> (internal and external DNS, points to <em>icrm </em>internally and <em>ecrm </em>externally)</li>
<li><em>crm</em> (internal and external DNS, points to <em>ecrm </em>internally and externally)</li>
<li><em>crm-test</em> (internal and external DNS, points to <em>ecrm </em>internally and externally)</li>
</ul>
</li>
</ul>
<p>The DNS configuration, if wrong, at best, will break your IFD, and at worst break all access to Dynamics CRM, so be sure to get it right. If you get it right, and you configure the IFD right, your setup would work as follows:</p>
<ul>
<li>Internal clients access CRM at <a href="http://redirectingat.com?id=17923X751173&xs=1&url=https%3A%2F%2Ficrm.contoso.com%2FCRM&sref=rss">https://icrm.contoso.com/CRM</a> and <a href="http://redirectingat.com?id=17923X751173&xs=1&url=https%3A%2F%2Ficrm.contoso.com%2FCRM-Test&sref=rss">https://icrm.contoso.com/CRM-Test</a>. No ADFS authentication is required.</li>
<li>External clients access CRM at <a href="#">https://crm.contoso.com</a> and <a href="#">https://crm-test.contoso.com</a>. ADFS authentication is required.</li>
</ul>
<p>This unfortunately is not what we want. Instead, we want our users to use the external client domains whether they are internal or external. To do this requires no change to Dynamics CRM; rather, the solution is through Internet Information Services (IIS).</p>
<h3>Rewriting URLs with IIS</h3>
<p>Here’s what happens with the above configuration:</p>
<ol>
<li>User enters <a href="#">https://crm.contoso.com</a> or <a href="#">https://crm-test.contoso.com</a> in their browser.</li>
<li>The request is sent to the internal Dynamics CRM server, <em>icrm.contoso.com</em>.</li>
<li>Dynamics CRM calls ADFS to get credentials for the user.</li>
<li>ADFS can’t resolve the user’s credentials, because the host name is not known to ADFS.</li>
<li>User can’t access Dynamics CRM.</li>
</ol>
<p>Here’s what needs to happen:</p>
<ol>
<li>User enters <a href="#">https://crm.contoso.com</a> or <a href="#">https://crm-test.contoso.com</a> in their browser.</li>
<li>The request is sent to the internal Dynamics CRM server, <em>ecrm.contoso.com</em>.</li>
<li>IIS and the URL Rewrite module running on <em>ecrm.contoso.com</em> examine the request and identifies it as coming from an internal client (by IP address).</li>
<li>If the request is coming from an internal client, IIS redirects the client to <a href="#">https://icrm.contoso.com/crm</a> or <a href="http://redirectingat.com?id=17923X751173&xs=1&url=https%3A%2F%2Ficrm.contoso.com%2Fcrm-test&sref=rss">https://icrm.contoso.com/crm-test</a>.</li>
<li>Everything else works as expected.</li>
</ol>
<p>URL Rewriting rules live in the web.config file in the Dynamics CRM installation directory (by default, C:\Program Files\Microsoft Dynamics CRM\CRMWeb). Open this file and add the following to the &lt;rules&gt; section.</p>
<pre class="brush: xml; ">

&lt;rule name=&quot;Redirect Internal Connections&quot; stopProcessing=&quot;true&quot;&gt;
&lt;match url=&quot;(.*)&quot; /&gt;
&lt;conditions trackAllCaptures=&quot;true&quot;&gt;
&lt;add input=&quot;{REMOTE_ADDR}&quot; pattern=&quot;192\.168\.[0-9]{1,3}\.[0-9]{1,3}&quot; /&gt;
&lt;add input=&quot;{HTTP_HOST}&quot; pattern=&quot;([^\.]*)\.(.*)&quot; /&gt;
&lt;/conditions&gt;
&lt;action type=&quot;Redirect&quot; url=&quot;https://icrm.contoso.com/{C:1}/{R:1}&quot; appendQueryString=&quot;true&quot; redirectType=&quot;Found&quot; /&gt;
&lt;/rule&gt;
</pre>
<p>The only changes you need to make to the above are:</p>
<ol>
<li>Change the regular expression pattern in the REMOTE_ADDR line to match your internal IP addresses. (<a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fsupport.google.com%2Fgoogleanalytics%2Fbin%2Fanswer.py%3Fhl%3Den%26amp%3Banswer%3D55572&sref=rss">Google has a nice tool to help with this</a>.)</li>
<li>Change the url in the Redirect line to match the host name of your internal Dynamics CRM server.</li>
</ol>
<p>Do that, test it extensively (internally and externally), and then tell your users that the <em>one </em>URL they use to access Dynamics CRM is the only one they need to remember.</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=601&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2012/01/15/url-rewriting-for-user-friendly-urls-with-dynamics-crm-2011/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		</item>
		<item>
		<title>Fixing &#8216;State code or status code is invalid&#8217; errors when deleting solutions in Dynamics CRM 2011</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2012/01/13/fixing-state-code-or-status-code-is-invalid-errors-when-deleting-solutions-in-dynamics-crm-2011/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2012/01/13/fixing-state-code-or-status-code-is-invalid-errors-when-deleting-solutions-in-dynamics-crm-2011/#comments</comments>
		<pubDate>Fri, 13 Jan 2012 20:29:08 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Dynamics CRM]]></category>
		<category><![CDATA[errors]]></category>
		<category><![CDATA[solutions]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=590</guid>
		<description><![CDATA[<p>Working with <a href="http://crm.dynamics.com">Dynamics CRM 2011</a>, I started getting an error when attempting to delete a managed solution:</p>
<blockquote><p><strong>Error deleting a managed solution: State code or status code is invalid
</strong>State code is invalid or state code is valid but status code is invalid for a specified state code.<strong> </strong></p></blockquote>
<p>The ErrorDetails.txt file states the following &#8212; note the text in bold.</p>
<blockquote><p>Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: <strong>1 is not a valid status code for state code SavedQueryState.Inactive on savedquery.Detail</strong>:</p>
<p>Error Code -2147187704</p>
<p>CallStack
at Microsoft.Crm.Extensibility.VersionedPluginProxyStepBase.Execute(PipelineExecutionContext context)
at Microsoft.Crm.Extensibility.Pipeline.Execute(PipelineExecutionContext context)
at Microsoft.Crm.Extensibility.MessageProcessor.Execute(PipelineExecutionContext context)
at Microsoft.Crm.Extensibility.InternalMessageDispatcher.Execute(PipelineExecutionContext context)
at Microsoft.Crm.Extensibility.ExternalMessageDispatcher.ExecuteInternal(IInProcessOrganizationServiceFactory serviceFactory, IPlatformMessageDispatcherFactory dispatcherFactory, String messageName, String requestName, Int32 primaryObjectTypeCode, Int32 secondaryObjectTypeCode, ParameterCollection fields, CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId, Guid transactionContextId, Int32 invocationSource, Nullable`1 requestId, Version endpointVersion)
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.ExecuteRequest(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType)
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.Execute(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType)
</p></blockquote>
<p>This error came about after we marked some of the out-of-the-box views as Inactive (like &#8220;Accounts: Responded to Campaigns in Last 6 Months&#8221;). Looking at the database, the <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2012/01/13/fixing-state-code-or-status-code-is-invalid-errors-when-deleting-solutions-in-dynamics-crm-2011/">Fixing &#8216;State code or status code is invalid&#8217; errors when deleting solutions in Dynamics CRM 2011</a></span>]]></description>
			<content:encoded><![CDATA[<p>Working with <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fcrm.dynamics.com&sref=rss">Dynamics CRM 2011</a>, I started getting an error when attempting to delete a managed solution:</p>
<blockquote><p><strong>Error deleting a managed solution: State code or status code is invalid<br />
</strong>State code is invalid or state code is valid but status code is invalid for a specified state code.<strong> </strong></p></blockquote>
<p>The ErrorDetails.txt file states the following &#8212; note the text in bold.</p>
<blockquote><p>Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: <strong>1 is not a valid status code for state code SavedQueryState.Inactive on savedquery.Detail</strong>:</p>
<p>Error Code -2147187704</p>
<p>CallStack<br />
at Microsoft.Crm.Extensibility.VersionedPluginProxyStepBase.Execute(PipelineExecutionContext context)<br />
at Microsoft.Crm.Extensibility.Pipeline.Execute(PipelineExecutionContext context)<br />
at Microsoft.Crm.Extensibility.MessageProcessor.Execute(PipelineExecutionContext context)<br />
at Microsoft.Crm.Extensibility.InternalMessageDispatcher.Execute(PipelineExecutionContext context)<br />
at Microsoft.Crm.Extensibility.ExternalMessageDispatcher.ExecuteInternal(IInProcessOrganizationServiceFactory serviceFactory, IPlatformMessageDispatcherFactory dispatcherFactory, String messageName, String requestName, Int32 primaryObjectTypeCode, Int32 secondaryObjectTypeCode, ParameterCollection fields, CorrelationToken correlationToken, CallerOriginToken originToken, UserAuth userAuth, Guid callerId, Guid transactionContextId, Int32 invocationSource, Nullable`1 requestId, Version endpointVersion)<br />
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.ExecuteRequest(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType)<br />
at Microsoft.Crm.Extensibility.OrganizationSdkServiceInternal.Execute(OrganizationRequest request, CorrelationToken correlationToken, CallerOriginToken callerOriginToken, WebServiceType serviceType)
</p></blockquote>
<p>This error came about after we marked some of the out-of-the-box views as Inactive (like &#8220;Accounts: Responded to Campaigns in Last 6 Months&#8221;). Looking at the database, the statecode (Status) and statuscode (Status Reason) for these views (in table SavedQueryBase) were both &#8220;1&#8243;. There was a simple workaround to this: change the statuscode to &#8220;2&#8243;, using the following SQL.</p>
<pre class="brush: sql; ">
update savedquerybase
set statuscode = 2
where statuscode = 1
and statecode = 1
</pre>
<p>That allowed the solution to delete without error, and the views I wanted inactivated were still inactive. Seems a bug in Dynamics CRM 2011, but I can&#8217;t say for sure.</p>
<p>Of course, use this as your own risk!</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=590&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2012/01/13/fixing-state-code-or-status-code-is-invalid-errors-when-deleting-solutions-in-dynamics-crm-2011/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Troubleshooting Windows Authentication in IIS</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2011/11/04/troubleshooting-windows-authentication-in-iis/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2011/11/04/troubleshooting-windows-authentication-in-iis/#comments</comments>
		<pubDate>Fri, 04 Nov 2011 13:26:46 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Authentication]]></category>
		<category><![CDATA[IIS]]></category>
		<category><![CDATA[Internet Explorer]]></category>
		<category><![CDATA[Kerberos]]></category>
		<category><![CDATA[NTLM]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=582</guid>
		<description><![CDATA[<p>In a recent deployment of Microsoft Dynamics CRM 2011, users were accessing the application via the server&#8217;s host name, e.g. https://crmserver01.company.com. That is rather unfriendly, so we created a new DNS record for crm.company.com &#8212; giving users the easier-to-remember https://crm.company.com (and removing a dependency on a server name).</p>
<p>Unfortunately, authenticating to https://crm.company.com didn&#8217;t work for <a href="http://www.iesucks.info/">Internet Explorer</a> users. IE would prompt for the credentials, but they were never accepted. Authentication did work for other browsers, and all browsers &#8212; including IE &#8212; were able to authenticate to https://crmserver01.company.com without issue.</p>
<p>This didn&#8217;t make sense. The domain name of the server shouldn&#8217;t matter (both were in IE&#8217;s Local Intranet Zone), nor should the browser version. But the different experience between browsers was all I had to go on, so I did some (network) sniffing.</p>
<p>Using <a href="http://www.fiddler2.com/fiddler2/">Fiddler2</a> to monitor the network traffic created by web browsers, I opened <a href="http://www.mozilla.org/en-US/firefox/fx/?from=getfirefox">Firefox</a> and connected to http://crm.company.com (no SSL, so it&#8217;s easier to monitor network traffic). Firefox <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2011/11/04/troubleshooting-windows-authentication-in-iis/">Troubleshooting Windows Authentication in IIS</a></span>]]></description>
			<content:encoded><![CDATA[<p>In a recent deployment of Microsoft Dynamics CRM 2011, users were accessing the application via the server&#8217;s host name, e.g. https://crmserver01.company.com. That is rather unfriendly, so we created a new DNS record for crm.company.com &#8212; giving users the easier-to-remember https://crm.company.com (and removing a dependency on a server name).</p>
<p>Unfortunately, authenticating to https://crm.company.com didn&#8217;t work for <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.iesucks.info%2F&sref=rss">Internet Explorer</a> users. IE would prompt for the credentials, but they were never accepted. Authentication did work for other browsers, and all browsers &#8212; including IE &#8212; were able to authenticate to https://crmserver01.company.com without issue.</p>
<p>This didn&#8217;t make sense. The domain name of the server shouldn&#8217;t matter (both were in IE&#8217;s Local Intranet Zone), nor should the browser version. But the different experience between browsers was all I had to go on, so I did some (network) sniffing.</p>
<p>Using <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.fiddler2.com%2Ffiddler2%2F&sref=rss">Fiddler2</a> to monitor the network traffic created by web browsers, I opened <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.mozilla.org%2Fen-US%2Ffirefox%2Ffx%2F%3Ffrom%3Dgetfirefox&sref=rss">Firefox</a> and connected to http://crm.company.com (no SSL, so it&#8217;s easier to monitor network traffic). Firefox prompted me for my password, I typed it in, and was taken to the Dynamics CRM &#8220;unsupported browser&#8221; page. (That lack of support for non-IE browsers is a separate issue, but <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fcommunity.dynamics.com%2Fproduct%2Fcrm%2Fcrmtechnical%2Fb%2Fcrmbusiness%2Farchive%2F2011%2F09%2F06%2Fmicrosoft-dynamics-crm-will-offer-cross-browser-support-chrome-firefox-and-safari-in-future-updates.aspx&sref=rss">a fix is supposedly in the works</a>.)</p>
<p>Here&#8217;s what Fiddler reported for those requests. I&#8217;ve truncated the request/response text to only show what&#8217;s relevant.</p>
<ol>
<li>Request<br />
GET http://crm.company.com</li>
<li>Response<br />
HTTP/1.1 401 Unauthorized<br />
WWW-Authenticate: Negotiate<br />
WWW-Authenticate: NTLM</li>
<li>Request<br />
GET http://crm.company.com<br />
Authorization: NTLM &lt;token&gt;</li>
</ol>
<p>The responses after that don&#8217;t matter; I&#8217;m connected. I then did the same steps with Internet Explorer: connected to http://crm.company.com, get prompted for the password, type the password, get prompted again, wash rinse repeat two times, then get the boilerplate &#8220;401 Unauthorize&#8221; page. Here&#8217;s the Fiddler report:</p>
<ol>
<li>Request<br />
<code>GET http://crm.company.com</code></li>
<li>Response<br />
<code>HTTP/1.1 401 Unauthorized<br />
WWW-Authenticate: Negotiate<br />
WWW-Authenticate: NTLM</code></li>
<li>Request<br />
<code>GET http://crm.company.com<br />
Authorization: Negotiate &lt;token&gt;</code></li>
</ol>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/iis-enabled-providers.png"><img class="alignright size-full wp-image-584" style="margin: 0pt 0pt 1em 2em;" title="IIS7 Providers for Windows Authentication" src="http://www.sidesofmarch.com/wp-content/uploads/iis-enabled-providers.png" alt="IIS7 comes with Negotiate (Kerberos) and NTLM providers for Windows Authentication" width="376" height="310" /></a>Note the difference? Firefox uses NTLM to authenticate; IE uses Negotiate (Kerberos). This was the root of the problem: Kerberos isn&#8217;t permitted to authorize users accessing crm.company.com, but it is permitted to authorize users accessing crmserver01.company.com. NTLM doesn&#8217;t have that restriction. So, it&#8217;ll always work in non-IE (non-Kerberos) browsers; and it will work to the host name URL in IE browsers; but it won&#8217;t work to the alternate host name in IE.</p>
<p>How do you fix this? By reading the blog post, <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fdevelopers.de%2Fblogs%2Fdamir_dobric%2Farchive%2F2009%2F08%2F16%2Fconfiguring-and-troubleshooting-ntlm-and-kerberos-on-windows-7-windows-server-2008-and-iis7.aspx&sref=rss">Configuring and Troubleshooting NTLM and Kerberos on Windows 7 (Windows Server 2008) and IIS7</a>. Essentially, you tell the server to allow Kerberos to the &#8220;other&#8221; domain name by running the following command from the console: <code>setspn -A HTTP/crm.company.com crmserver01</code></p>
<p>Another solution is to configure your web site to only use NTLM authentication, or to give NTLM authentication higher priority than Kerberos. However, this is more a workaround than a fix: the point of IE/Windows is to use Kerberos, not to avoid it. Still, it&#8217;s an option if you can&#8217;t run the <code>setspn</code> command for some reason.</p>
<p>Once you do either of those, all browsers will work to either domain name, as you would expect, and your users will be happy. <img src='http://www.sidesofmarch.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=582&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2011/11/04/troubleshooting-windows-authentication-in-iis/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting the entity owner to a team using Scribe Insight and Dynamics CRM 2011</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2011/08/15/setting-the-entity-owner-to-a-team-using-scribe-insight-and-dynamics-crm-2011/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2011/08/15/setting-the-entity-owner-to-a-team-using-scribe-insight-and-dynamics-crm-2011/#comments</comments>
		<pubDate>Mon, 15 Aug 2011 22:02:51 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[Dynamics CRM]]></category>
		<category><![CDATA[Scribe Insight]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=579</guid>
		<description><![CDATA[<p>While working on migrating data from a legacy CRM system to <a href="http://crm.dynamics.com/en-us/home">Microsoft Dynamics CRM 2011</a> using <a href="http://www.scribesoft.com/Insight.asp">Scribe Insight</a>, I decided to set the owner of all migrated entities to a specific team (rather than the default, which is the Dynamics user specified in the Scribe connection). To do this seemingly would require one simple steps: to look up the GUID of the team, and set the value of the Dynamics CRM &#8220;ownerid&#8221; to that value.</p>
<p><strong>To set the &#8220;ownerid&#8221;</strong> I used the DBLOOKUP command to look up the team by name, and return the teamid: DBLOOKUP( &#8220;MyTeamName&#8221;, &#8220;CRM&#8221;, &#8220;team&#8221;, &#8220;name&#8221;, &#8220;teamid&#8221; ). This worked fine, but on its own, Dynamics threw an error, saying that the GUID wasn&#8217;t valid.</p>
<p>The problem lies in how Dynamics manages owners: an owner can be a user or a team. The owner of an entity is assumed to be a user unless you change the &#8220;owneridtype&#8221; field, which is visible in Scribe but is not <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2011/08/15/setting-the-entity-owner-to-a-team-using-scribe-insight-and-dynamics-crm-2011/">Setting the entity owner to a team using Scribe Insight and Dynamics CRM 2011</a></span>]]></description>
			<content:encoded><![CDATA[<p>While working on migrating data from a legacy CRM system to <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fcrm.dynamics.com%2Fen-us%2Fhome&sref=rss">Microsoft Dynamics CRM 2011</a> using <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.scribesoft.com%2FInsight.asp&sref=rss">Scribe Insight</a>, I decided to set the owner of all migrated entities to a specific team (rather than the default, which is the Dynamics user specified in the Scribe connection). To do this seemingly would require one simple steps: to look up the GUID of the team, and set the value of the Dynamics CRM &#8220;ownerid&#8221; to that value.</p>
<p><strong>To set the &#8220;ownerid&#8221;</strong> I used the DBLOOKUP command to look up the team by name, and return the teamid: DBLOOKUP( &#8220;MyTeamName&#8221;, &#8220;CRM&#8221;, &#8220;team&#8221;, &#8220;name&#8221;, &#8220;teamid&#8221; ). This worked fine, but on its own, Dynamics threw an error, saying that the GUID wasn&#8217;t valid.</p>
<p>The problem lies in how Dynamics manages owners: an owner can be a user or a team. The owner of an entity is assumed to be a user unless you change the &#8220;owneridtype&#8221; field, which is visible in Scribe but is not listed in the Dynamics data dictionary (as far as I could tell). If the owner is a user, the &#8220;useridtype&#8221; should be 8. If the owner is a team, the &#8220;useridtype&#8221; should be 9.</p>
<p>After setting the &#8220;useridtype&#8221; to 9, Dynamics accepted the GUID of my team in the &#8220;ownerid&#8221; field. Problem solved!</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=579&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2011/08/15/setting-the-entity-owner-to-a-team-using-scribe-insight-and-dynamics-crm-2011/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>An exercise in frustration: Getting product keys and support using the Microsoft Dynamics CustomerSource web site</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2011/08/12/an-exercise-in-frustration-getting-product-keys-and-support-using-the-microsoft-dynamics-customersource-web-site/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2011/08/12/an-exercise-in-frustration-getting-product-keys-and-support-using-the-microsoft-dynamics-customersource-web-site/#comments</comments>
		<pubDate>Fri, 12 Aug 2011 15:27:38 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[CustomerSource]]></category>
		<category><![CDATA[Dynamics]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[support]]></category>
		<category><![CDATA[Usability]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=568</guid>
		<description><![CDATA[<p>&#8220;Microsoft Dynamics <a href="https://mbs.microsoft.com/customersource">CustomerSource</a> is an information-packed,  password-protected site for customers who use Microsoft Dynamics  products.&#8221; (<a href="https://www.microsoft.com/dynamics/en/au/customersource.aspx">Microsoft&#8217;s words, not mine</a>.) I decided to use this information-packed, password-protected site to get my recently purchased product keys for Dynamics CRM 2011.</p>
<p>Below is a summary of my experience.</p>
<p>First, I go to the <em>Product &#38; Service</em> summary page on the <em>My Account</em> page.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-1.png"></a></p>
<p>Then, I click on <em>Registration Keys</em>.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-2.png"></a></p>
<p>Then, I choose the appropriate version (2011) and upgrade option (No) and get the following message: “The keys you are trying are of Volume license, hence they will not be shown from MBS.” (I have no idea what MBS is.)</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-3.png"></a></p>
<p>Frustrated, I try getting support by clicking the support link on the “Contact Dynamics Operations” page.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-4.png"></a></p>
<p>Which yields a very unhelpful support page that tells me, &#8220;Our apologies&#8230;An unexpected error occurred.&#8221; At least they are apologetic.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-5.png"></a></p>
<p>Despairingly, I click the <em>ROC Contact Information</em> at the bottom of the page (I have no idea <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2011/08/12/an-exercise-in-frustration-getting-product-keys-and-support-using-the-microsoft-dynamics-customersource-web-site/">An exercise in frustration: Getting product keys and support using the Microsoft Dynamics CustomerSource web site</a></span>]]></description>
			<content:encoded><![CDATA[<p>&#8220;Microsoft Dynamics <a href="http://redirectingat.com?id=17923X751173&xs=1&url=https%3A%2F%2Fmbs.microsoft.com%2Fcustomersource&sref=rss">CustomerSource</a> is an information-packed,  password-protected site for customers who use Microsoft Dynamics  products.&#8221; (<a href="http://redirectingat.com?id=17923X751173&xs=1&url=https%3A%2F%2Fwww.microsoft.com%2Fdynamics%2Fen%2Fau%2Fcustomersource.aspx&sref=rss">Microsoft&#8217;s words, not mine</a>.) I decided to use this information-packed, password-protected site to get my recently purchased product keys for Dynamics CRM 2011.</p>
<p>Below is a summary of my experience.</p>
<p>First, I go to the <em>Product &amp; Service</em> summary page on the <em>My Account</em> page.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-1.png"><img class="alignnone size-full wp-image-576" title="Dynamics CustomerSource &quot;My Account&quot; page" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-1.png" alt="" width="462" height="360" /></a></p>
<p>Then, I click on <em>Registration Keys</em>.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-2.png"><img class="alignnone size-full wp-image-571" title="Dynamics CustomerSource &quot;Product and Service Summary&quot; page" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-2.png" alt="" width="461" height="384" /></a></p>
<p>Then, I choose the appropriate version (2011) and upgrade option (No) and get the following message: “The keys you are trying are of Volume license, hence they will not be shown from MBS.” (I have no idea what MBS is.)</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-3.png"><img class="alignnone size-full wp-image-572" title="Dynamics CustomerSource &quot;Request License Keys&quot; page" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-3.png" alt="" width="470" height="335" /></a></p>
<p>Frustrated, I try getting support by clicking the support link on the “Contact Dynamics Operations” page.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-4.png"><img class="alignnone size-full wp-image-573" title="Dynamics CustomerSource &quot;Contact Dynamics Operations&quot; Page" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-4.png" alt="" width="462" height="385" /></a></p>
<p>Which yields a very unhelpful support page that tells me, &#8220;Our apologies&#8230;An unexpected error occurred.&#8221; At least they are apologetic.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-5.png"><img class="alignnone size-full wp-image-574" title="Dynamics CustomerSource &quot;Unexpected Error&quot; support page" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-5.png" alt="" width="470" height="319" /></a></p>
<p>Despairingly, I click the <em>ROC Contact Information</em> at the bottom of the page (I have no idea what “ROC” is) and get a different apologetic error.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-6.png"><img class="alignnone size-full wp-image-575" title="DDynamics CustomerSource &quot;Not Authorized&quot; contact page" src="http://www.sidesofmarch.com/wp-content/uploads/Dynamics-CustomerSource-6.png" alt="" width="461" height="383" /></a></p>
<p>Pretty unimpressive, even for Microsoft.</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=568&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2011/08/12/an-exercise-in-frustration-getting-product-keys-and-support-using-the-microsoft-dynamics-customersource-web-site/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CSS Friendly Control Adapters now available on NuGet</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2011/05/20/css-friendly-control-adapters-now-available-on-nuget/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2011/05/20/css-friendly-control-adapters-now-available-on-nuget/#comments</comments>
		<pubDate>Fri, 20 May 2011 23:32:56 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[ASP.Net]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[CSSFriendly]]></category>
		<category><![CDATA[Web Forms]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=538</guid>
		<description><![CDATA[<p>Back in the days of <a href="http://www.asp.net/web-forms">Web Forms</a>, there were server controls, and they generated rather CSS-unfriendly HTML. So, Microsoft got someone (<a href="http://www.groovybits.com/">Russ Helfand</a>) to write adapters that changed their rendering to be more CSS-friendly: the “<strong>CSS Friendly Control Adapters</strong>” were born.</p>
<p>A little less farther back, in 2007, I tried convincing some people at Microsoft to let the community continue development of these adapters, and they agreed. The <a href="http://cssfriendly.codeplex.com/">CSSFriendly CodePlex project</a> was born, and a bunch of bugs and some new features were added.</p>
<p>A lot has changed since then, but the adapters still have use today for people stuck on .Net 2.0 (they’re in the top 200 most downloaded CodePlex projects, and <a href="http://forums.asp.net/1018.aspx/1?CSS+Friendly+Control+Adapters">their forums still see activity</a>). To facilitate those who still use CSSFriendly, I’ve <a href="http://nuget.org/List/Packages/CSSFriendly">added the library package to NuGet</a>.</p>
<p><strong>How to use the CSSFriendly NuGet package</strong></p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/cssfriendly-nuget-package1.png"></a>In four easy steps (three if you already have NuGet).</p>

First, you need Visual Studio 2010 and <a href="http://nuget.org/">NuGet</a>. (If you’re <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2011/05/20/css-friendly-control-adapters-now-available-on-nuget/">CSS Friendly Control Adapters now available on NuGet</a></span>]]></description>
			<content:encoded><![CDATA[<p>Back in the days of <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.asp.net%2Fweb-forms&sref=rss">Web Forms</a>, there were server controls, and they generated rather CSS-unfriendly HTML. So, Microsoft got someone (<a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fwww.groovybits.com%2F&sref=rss">Russ Helfand</a>) to write adapters that changed their rendering to be more CSS-friendly: the “<strong>CSS Friendly Control Adapters</strong>” were born.</p>
<p>A little less farther back, in 2007, I tried convincing some people at Microsoft to let the community continue development of these adapters, and they agreed. The <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fcssfriendly.codeplex.com%2F&sref=rss">CSSFriendly CodePlex project</a> was born, and a bunch of bugs and some new features were added.</p>
<p>A lot has changed since then, but the adapters still have use today for people stuck on .Net 2.0 (they’re in the top 200 most downloaded CodePlex projects, and <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fforums.asp.net%2F1018.aspx%2F1%3FCSS%2BFriendly%2BControl%2BAdapters&sref=rss">their forums still see activity</a>). To facilitate those who still use CSSFriendly, I’ve <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fnuget.org%2FList%2FPackages%2FCSSFriendly&sref=rss">added the library package to NuGet</a>.</p>
<p><strong>How to use the CSSFriendly NuGet package</strong></p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/cssfriendly-nuget-package1.png"><img style="background-image: none; margin: 0px 0px 16px 16px; padding-left: 0px; padding-right: 0px; display: inline; float: right; padding-top: 0px; border: 0px;" title="cssfriendly-nuget-package" src="http://www.sidesofmarch.com/wp-content/uploads/cssfriendly-nuget-package_thumb1.png" border="0" alt="cssfriendly-nuget-package" width="433" height="218" align="right" /></a>In four easy steps (three if you already have NuGet).</p>
<ol>
<li>First, you need Visual Studio 2010 and <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fnuget.org%2F&sref=rss">NuGet</a>. (If you’re new to NuGet, <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fdocs.nuget.org%2F&sref=rss">read the getting started documentation</a>.)</li>
<li>Next, right-click the <strong>References</strong> folder and choose <strong>Add Library Package Reference</strong>.</li>
<li>In the Add Library Package Reference window, search for “cssfriendly.”</li>
<li>When you see the CSSFriendly package, click the Install button.</li>
</ol>
<p>After it installs, the following is added to your project:</p>
<ul>
<li>The CSSFriendly library reference</li>
<li>The CSSFriendlyAdapters.browser file in the App_Browsers folder</li>
</ul>
<p>At that point, you’re ready to go!</p>
<p>The full source of the CSSFriendly library is still available at CodePlex: <a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fcssfriendly.codeplex.com&sref=rss">http://cssfriendly.codeplex.com</a>. Downloads there include sample code and walkthroughs.</p>
<p>Enjoy, and let me know if you have any issues!</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=538&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2011/05/20/css-friendly-control-adapters-now-available-on-nuget/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Beer and Taxes</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2011/04/25/beer-and-taxes/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2011/04/25/beer-and-taxes/#comments</comments>
		<pubDate>Mon, 25 Apr 2011 12:30:11 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Liberty]]></category>
		<category><![CDATA[Taxes]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=530</guid>
		<description><![CDATA[<p>The following has been circulated around for a long time. It just resurfaced to me, and I wanted to share it! I wish I knew who to credit it to.  </p>
<blockquote><p>Suppose that every day, ten men go out for beer and the bill for all ten comes to $100.
If they paid their bill the way we pay our taxes, it would go something like this&#8230;</p>
<p>The first four men (the poorest) would pay nothing
The fifth would pay $1
The sixth would pay $3
The seventh would pay $7
The eighth would pay $12
The ninth would pay $18
The tenth man (the richest) would pay $59</p>
<p>So, that&#8217;s what they decided to do.</p>
<p>The  ten men drank in the bar every day and seemed quite happy with the  arrangement, until one day, the owner threw them a curve ball. &#8220;Since  you are all such good customers,&#8221; he said, &#8220;I&#8217;m going to reduce the cost  of your daily beer by $20&#8243;. Drinks for the ten <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2011/04/25/beer-and-taxes/">Beer and Taxes</a></span>]]></description>
			<content:encoded><![CDATA[<p>The following has been circulated around for a long time. It just resurfaced to me, and I wanted to share it! I wish I knew who to credit it to. <img src='http://www.sidesofmarch.com/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
<blockquote><p>Suppose that every day, ten men go out for beer and the bill for all ten comes to $100.<br />
If they paid their bill the way we pay our taxes, it would go something like this&#8230;</p>
<p>The first four men (the poorest) would pay nothing<br />
The fifth would pay $1<br />
The sixth would pay $3<br />
The seventh would pay $7<br />
The eighth would pay $12<br />
The ninth would pay $18<br />
The tenth man (the richest) would pay $59</p>
<p>So, that&#8217;s what they decided to do.</p>
<p>The  ten men drank in the bar every day and seemed quite happy with the  arrangement, until one day, the owner threw them a curve ball. &#8220;Since  you are all such good customers,&#8221; he said, &#8220;I&#8217;m going to reduce the cost  of your daily beer by $20&#8243;. Drinks for the ten men would now cost just  $80.</p>
<p>The group still wanted to pay their bill the way we pay our  taxes. So the first four men were unaffected. They would still drink for  free. But what about the other six men ? How could they divide the $20  windfall so that everyone would get his fair share?</p>
<p>They realized  that $20 divided by six is $3.33. But if they subtracted that from  everybody&#8217;s share, then the fifth man and the sixth man would each end  up being paid to drink his beer.</p>
<p>So, the bar owner suggested that  it would be fair to reduce each man&#8217;s bill by a higher percentage the  poorer he was, to follow the principle of the tax system they had been  using, and he proceeded to work out the amounts he suggested that each  should now pay.</p>
<p>And so the fifth man, like the first four, now paid nothing (100% saving).<br />
The sixth now paid $2 instead of $3 (33% saving).<br />
The seventh now paid $5 instead of $7 (28% saving).<br />
The eighth now paid $9 instead of $12 (25% saving).<br />
The ninth now paid $14 instead of $18 (22% saving).<br />
The tenth now paid $49 instead of $59 (16% saving).</p>
<p>Each  of the six was better off than before. And the first four continued to  drink for free. But, once outside the bar, the men began to compare  their savings.</p>
<p>&#8220;I only got a dollar out of the $20 saving,&#8221; declared the sixth man. He pointed to the tenth man,&#8221;but he got $10!&#8221;</p>
<p>&#8220;Yeah,  that&#8217;s right,&#8221; exclaimed the fifth man. &#8220;I only saved a dollar too.  It&#8217;s unfair that he got ten times more benefit than me!&#8221;</p>
<p>&#8220;That&#8217;s true!&#8221; shouted the seventh man. &#8220;Why should he get $10 back, when I got only $2? The wealthy get all the breaks!&#8221;</p>
<p>&#8220;Wait a minute,&#8221; yelled the first four men in unison, &#8220;we didn&#8217;t get anything at all. This new tax system exploits the poor!&#8221;</p>
<p>The nine men surrounded the tenth and beat him up.</p>
<p>The  next night the tenth man didn&#8217;t show up for drinks so the nine sat down  and had their beers without him. But when it came time to pay the bill,  they discovered something important. They didn&#8217;t have enough money  between all of them for even half of the bill!</p></blockquote>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=530&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2011/04/25/beer-and-taxes/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Insufficient pagefile size can cause obscure memory errors</title>
		<link>http://www.sidesofmarch.com/index.php/archive/2011/03/22/insufficient-pagefile-size-can-cause-obscure-memory-errors/</link>
		<comments>http://www.sidesofmarch.com/index.php/archive/2011/03/22/insufficient-pagefile-size-can-cause-obscure-memory-errors/#comments</comments>
		<pubDate>Tue, 22 Mar 2011 16:26:36 +0000</pubDate>
		<dc:creator>brian</dc:creator>
				<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://www.sidesofmarch.com/?p=523</guid>
		<description><![CDATA[<p>Today, a user reported an issue connecting to a very old CRM application. I logged in to the system myself and saw no error. Since I&#8217;m not happy with self-healing issues, I went digging into the event log on the server.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/registry-failed-unrecoverably-event-log.png"></a>For the past five days, there have been over 15,000 entries added to the System event log with event ID 333: &#8220;An I/O operation initiated by the Registry failed unrecoverably. The Registry could not read in, or write out, or flush, one of the files that contain the system&#8217;s image of the Registry.&#8221; That doesn&#8217;t sound good.</p>
<p>My first stop for analyzing event log errors is <a title="EventID.Net - Troubleshooting over 10,000 Windows event log entries" href="http://eventid.net">eventid.net</a>. The <a title="Event ID 333 Source Application Popup (eventid.net)" href="http://eventid.net/display.asp?eventid=333&#38;eventno=5757&#38;source=Application%20Popup&#38;phase=1">feedback on their site</a> pointed me to a few possibilities.</p>

The /3GB switch on a system with 2GB or less of memory.
Symantec AntiVirus (which is a potential culprit to every system problem, apparently).
Insufficient Non Paged Memory <span style="color:#777"> . . .<br /><br />&#8594; Read More: <a href="http://www.sidesofmarch.com/index.php/archive/2011/03/22/insufficient-pagefile-size-can-cause-obscure-memory-errors/">Insufficient pagefile size can cause obscure memory errors</a></span>]]></description>
			<content:encoded><![CDATA[<p>Today, a user reported an issue connecting to a very old CRM application. I logged in to the system myself and saw no error. Since I&#8217;m not happy with self-healing issues, I went digging into the event log on the server.</p>
<p><a href="http://www.sidesofmarch.com/wp-content/uploads/registry-failed-unrecoverably-event-log.png"><img class="alignright size-medium wp-image-524" title="Windows System Event Log error: &quot;An I/O operation initiated by the Registry failed unrecoverably.&quot;" src="http://www.sidesofmarch.com/wp-content/uploads/registry-failed-unrecoverably-event-log-269x300.png" alt="" width="269" height="300" /></a>For the past five days, there have been over 15,000 entries added to the System event log with event ID 333: &#8220;An I/O operation initiated by the Registry failed unrecoverably. The Registry could not read in, or write out, or flush, one of the files that contain the system&#8217;s image of the Registry.&#8221; That doesn&#8217;t sound good.</p>
<p>My first stop for analyzing event log errors is <a title="EventID.Net - Troubleshooting over 10,000 Windows event log entries" href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Feventid.net&sref=rss">eventid.net</a>. The <a title="Event ID 333 Source Application Popup (eventid.net)" href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Feventid.net%2Fdisplay.asp%3Feventid%3D333%26amp%3Beventno%3D5757%26amp%3Bsource%3DApplication%2520Popup%26amp%3Bphase%3D1&sref=rss">feedback on their site</a> pointed me to a few possibilities.</p>
<ul>
<li>The /3GB switch on a system with 2GB or less of memory.</li>
<li>Symantec AntiVirus (which is a potential culprit to every system problem, apparently).</li>
<li>Insufficient Non Paged Memory or Paged Pool Memory.</li>
<li>Disk or I/O subsystem errors.</li>
<li>Overaggressive SQL Server memory usage or I/O affinity.</li>
</ul>
<p>I checked the server&#8217;s memory capacity: 3GB. I checked memory usage in Task Manager: about the same. I checked the page file size, and saw the following (note the highlighted sections).</p>
<div><a href="http://www.sidesofmarch.com/wp-content/uploads/bad-page-file.png"><img class="aligncenter size-medium wp-image-525" title="Page file settings shouldn't be less than the amount of physical RAM!" src="http://www.sidesofmarch.com/wp-content/uploads/bad-page-file.png" alt="" /></a></div>
<p>Ouch! Microsoft has a nice knowledge base article, affectionately titled, <em><a href="http://redirectingat.com?id=17923X751173&xs=1&url=http%3A%2F%2Fsupport.microsoft.com%2Fkb%2F2267427&sref=rss">RAM, Virtual Memory, Pagefile, and all that stuff</a></em>, which suggests, as a baseline recommendation, that a pagefile should equal &#8220;1.5 times the amount of RAM that is in the computer.&#8221; As always, your mileage may vary, but generally speaking, the recommendation is sound. Or, you can just click the &#8220;System managed size&#8221; option, and forget about it altogether.</p>
<p>The lesson here: <strong>check your pagefile settings when setting up a computer, and always revisit them whenever the amount of physical RAM changes</strong>.</p>
<img src="http://www.sidesofmarch.com/?ak_action=api_record_view&id=523&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://www.sidesofmarch.com/index.php/archive/2011/03/22/insufficient-pagefile-size-can-cause-obscure-memory-errors/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

