C# XAML节点流:在EndObject之前缺少CurrentObject

C# XAML节点流:在EndObject之前缺少CurrentObject,c#,.net,wpf,xaml,workflow,C#,.net,Wpf,Xaml,Workflow,我在工作流服务中遇到以下错误。我在谷歌上搜索过,但没有找到任何有用的信息。我找到了这个链接,但无法理解它。 问题随机发生,内部异常为 位于System.Xaml.XamlObjectWriter.WriteEndObject()处 位于System.Xaml.XamlObjectWriter.Dispose(布尔处理) 位于System.Xaml.XamlWriter.System.IDisposable.Dispose()处 位于System.Activities.XamIntegratio

我在工作流服务中遇到以下错误。我在谷歌上搜索过,但没有找到任何有用的信息。我找到了这个链接,但无法理解它。

问题随机发生,内部异常为

位于System.Xaml.XamlObjectWriter.WriteEndObject()处
位于System.Xaml.XamlObjectWriter.Dispose(布尔处理)
位于System.Xaml.XamlWriter.System.IDisposable.Dispose()处
位于System.Activities.XamIntegration.ActivityXamlServices.InitializeComponentFromXamlResource(类型componentType,字符串资源,对象componentInstance,XamlSchemaContext schemaContext)

在System.Activities.XamIntegration.ActivityXamlServices.InitializeComponent(类型componentType,对象componentInstance)

以防有人需要答案: 从项目中删除System.Activities.Presentation、PresentationCore、PresentationFramework和WindowsBase模块的引用

同时检查GC模式,在运行时它应该获得在多核上运行的好处。要启用服务器模式,请执行以下操作:

<configuration>  
   <runtime>  
      <gcServer enabled="true"/>  
   </runtime>  
</configuration> 

有关更多详细信息,请参阅gcServer文档: