2009-11-24 50 views
2

我们为SharePoint MOSS开发了一个自定义Visual Studio工作流程。它为文档批准过程创建任务,并在我们的开发机器上正常工作。我们正在使用主要工作流程活动和一个自定义的儿童活动。我们使用绑定属性将它们传递给整个工作流程,我们认为所有标准的Windows工作流程都可以通过。当我们部署SharePoint时,Windows工作流程中断

当我们将此工作流程部署到我们的测试服务器(这是一个小型服务器场)时,我们的taskproperties/workflowproperties似乎都评估为null。

我们尝试了许多不同的方法来解决这个问题,包括以admin帐户运行工作流程,在代码中手动重新创建taskproperties等等,但没有取得任何成功。

任何人都可以阐明可能是什么问题,任何光线,错误详述如下,万事如意,

低于此错误是一个内部错误,而且似乎指向一个错误创建任务时与内容类型(SPWinOETaskService.CreateTaskWithContentType)。

11/23/2009 19:09:54.47 w3wp.exe (0x1FB8)      0x1CDC Windows SharePoint Services Workflow Infrastructure  88xr Unexpected WinWF Internal Error, terminating workflow Id# 07ab6631-c656-4918-8ffe-7a09da3a3628 
    11/23/2009 19:09:54.47 w3wp.exe (0x1FB8)      0x1CDC Windows SharePoint Services Workflow Infrastructure  98d4 Unexpected System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.NullReferenceException: Object reference not set to an instance of an object.  at Microsoft.SharePoint.Workflow.SPWinOETaskService.CreateTaskWithContentTypeInternal(Guid taskId, SPWorkflowTaskProperties properties, Boolean useDefaultContentType, SPContentTypeId ctid, HybridDictionary specialPermissions)  at Microsoft.SharePoint.Workflow.SPWinOETaskService.CreateTaskWithContentType(Guid taskId, SPWorkflowTaskProperties properties, String taskContentTypeId, HybridDictionary specialPermissions)  --- End of inner exception stack trace ---  at System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAtt... 
    11/23/2009 19:09:54.47* w3wp.exe (0x1FB8)      0x1CDC Windows SharePoint Services Workflow Infrastructure  98d4 Unexpected ...ributes, RuntimeTypeHandle typeOwner)  at System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)  at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)  at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)  at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)  at System.Workflow.Activities.CallExternalMethodActivity.Execute(Acti... 
    11/23/2009 19:09:54.47* w3wp.exe (0x1FB8)      0x1CDC Windows SharePoint Services Workflow Infrastructure  98d4 Unexpected ...vityExecutionContext executionContext)  at System.Workflow.ComponentModel.ActivityExecutor`1.Execute(T activity, ActivityExecutionContext executionContext)  at System.Workflow.ComponentModel.ActivityExecutor`1.Execute(Activity activity, ActivityExecutionContext executionContext)  at System.Workflow.ComponentModel.ActivityExecutorOperation.Run(IWorkflowCoreRuntime workflowCoreRuntime)  at System.Workflow.Runtime.Scheduler.Run() 
+0

SharePoint是否偶然运行64位? – curtisk 2009-11-24 19:12:10

+0

它在开发机器上,在测试服务器上是32位。我们正在开发机器上的Visual Studio中编译为'Any CPU'。持续集成在部署测试时构建代码。所有最好的 – 78lro 2009-11-24 19:28:48

回答

0

我们发现,如果我们还没有添加任务内容类型的特定的工作流程任务列表,然后我们得到这个错误:

要做到这一点,在工作流列表高级设置,允许内容类型的mamangement。

然后,您可以在管理列表屏幕上添加现有内容类型并选择您自定义的内容类型。

然后,您的工作流程应该没有错误地工作。

hth

1

由于错误是CreateTaskWithContentType,你有没有创建任何内容类型,其可在开发计算机上,但尚未部署到测试服务器。

编辑

刚把再看看你的错误消息。我想知道是否SPWinOETaskService是什么是null。是否有与服务器场上未运行的工作流相关的服务?

+0

我们已确认内容类型和列已全部正确部署到两台机器上。创建任务的错误正在发生,因为它需要“创建”的对象为空......我们认为! – 78lro 2009-11-24 20:41:34

+0

您知道应该为工作流程运行哪些服务?我没有任何喜悦地用Google搜索SPWinOETaskService?谢谢 – 78lro 2009-11-25 21:19:16