Lets explore how it could happen.
Error Message:
Unhandled Exception: System.ServiceModel.FaultException`1[[Microsoft.Xrm.Sdk.OrganizationServiceFault, Microsoft.Xrm.Sdk, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: Plug-in assembly does not contain the required types or assembly content cannot be updated.
Detail: <OrganizationServiceFault xmlns="http://schemas.microsoft.com/xrm/2011/Contracts" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<ErrorCode>-2147204725</ErrorCode>
<ErrorDetails xmlns:a="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>Plug-in assembly does not contain the required types or assembly content cannot be updated.</Message>
<Timestamp>2011-06-20T08:31:56.6192334Z</Timestamp>
<InnerFault>
<ErrorCode>-2147204725</ErrorCode>
<ErrorDetails xmlns:a="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>Plug-in assembly does not contain the required types or assembly content cannot be updated.</Message>
<Timestamp>2011-06-20T08:31:56.6192334Z</Timestamp>
<InnerFault i:nil="true" />
<TraceText i:nil="true" />
</InnerFault>
<TraceText i:nil="true" />
</OrganizationServiceFault>
Detail: <OrganizationServiceFault xmlns="http://schemas.microsoft.com/xrm/2011/Contracts" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<ErrorCode>-2147204725</ErrorCode>
<ErrorDetails xmlns:a="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>Plug-in assembly does not contain the required types or assembly content cannot be updated.</Message>
<Timestamp>2011-06-20T08:31:56.6192334Z</Timestamp>
<InnerFault>
<ErrorCode>-2147204725</ErrorCode>
<ErrorDetails xmlns:a="http://schemas.datacontract.org/2004/07/System.Collections.Generic" />
<Message>Plug-in assembly does not contain the required types or assembly content cannot be updated.</Message>
<Timestamp>2011-06-20T08:31:56.6192334Z</Timestamp>
<InnerFault i:nil="true" />
<TraceText i:nil="true" />
</InnerFault>
<TraceText i:nil="true" />
</OrganizationServiceFault>
Server stack trace:
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
at System.ServiceModel.Channels.ServiceChannel.HandleReply(ProxyOperationRuntime operation, ProxyRpc& rpc)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.Xrm.Sdk.IOrganizationService.Update(Entity entity)
at Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.UpdateCore(Entity entity)
at PluginRegistrationTool.RegistrationHelper.UpdateAssembly(CrmOrganization org, String pathToAssembly, CrmPluginAssembly assembly) in C:\Users\Administrator\Desktop\CRMTools\CrmSDK2011\tools\pluginregistration\RegistrationHelper.cs:line 427
at PluginRegistrationTool.PluginRegistrationForm.btnRegister_Click(Object sender, EventArgs e) in C:\Users\Administrator\Desktop\CRMTools\CrmSDK2011\tools\pluginregistration\PluginRegistrationForm.cs:line 371
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Microsoft.Xrm.Sdk.IOrganizationService.Update(Entity entity)
at Microsoft.Xrm.Sdk.Client.OrganizationServiceProxy.UpdateCore(Entity entity)
at PluginRegistrationTool.RegistrationHelper.UpdateAssembly(CrmOrganization org, String pathToAssembly, CrmPluginAssembly assembly) in C:\Users\Administrator\Desktop\CRMTools\CrmSDK2011\tools\pluginregistration\RegistrationHelper.cs:line 427
at PluginRegistrationTool.PluginRegistrationForm.btnRegister_Click(Object sender, EventArgs e) in C:\Users\Administrator\Desktop\CRMTools\CrmSDK2011\tools\pluginregistration\PluginRegistrationForm.cs:line 371
When you are trying to update the plugin using Plugin registration tool in CRM 2011, then you might get this error if there are some mismatches between old assembly and new assembly.
Consider a scenario:
2 Developers John & Harry are working in the same project. They are retaining their source code in a version control. They have maintained one common dll for the plugin assembly using IL Merge to avoid dependency issues. ( How to use IL Merge Refer: http://crmdm.blogspot.com/2011/02/crm-cannot-find-plugin-assembly-or-one.html ) . Imagine there are a total number of 10 plugins already in the project. Now John develops a plugin and he updates the plugin assembly with his plugin. But he forgets to check in the source code of new plugin in the version control. Next day Harry would like to develop a plugin. He checks out latest source code(but John's plugin missing) from the version control and starts developing his plugin. When Harry tries to update the plugin assembly he would see the above error message. Harry must get the right previous version of plugin dll ( which includes John's plugin) because the last version in the assembly contains John's plugin. In simple words, when Harry tries to update the plugin assembly in CRM 2011, his dll should have required types or assembly content. This is a sample case of mismatch.
So if you get this error message just think of the possibilities of mismatch and then you could easily resolve it.