问题描述
- NativeActivityContext.GetValue()获取不到正确的传入参数
- 传入参数代码段:
Activity wf=‘某个Activity’;
WorkflowIdentity identity = ‘某个WorkflowIdentity’
Guid frameworkObjectId=‘某个Guid值,非Empty’;
IDictionary inputs = new Dictionary()
{
{""InFrameworkObjectId""frameworkObjectId}
};
wfApp = new WorkflowApplication(wf inputs identity);此处省略……
接下来进入工作流的第一步
是一个继承了NativeActivity的sealed类:public InArgument FrameworkObjectId { get; set; }
protected override void Execute(NativeActivityContext context) { Guid frameworkObjectId =context.GetValue(this.FrameworkObjectId); //这个方法获得的frameworkObjectId={0000-00000-000000000},即是Guid.Empty。而传入的不是Empty }
解决方案
NativeActivityContext.GetValue()获取不到正确的传入参数
没人回答吗?
时间: 2024-10-02 13:13:03