如何设置活动代表的所有者字段.

编程入门 行业动态 更新时间:2024-10-23 05:33:44
本文介绍了如何设置活动代表的所有者字段.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

I have the following bookmark handler code. But the last line keeps throughing an execption:ActivityDelegate 'ActivityFunc`1' should have an owner workflow element specified.How do I set the owner for this delegate. private

void onStart( NativeActivityContext 上下文, 书签 书签, 对象native _ activity){

void onStart(NativeActivityContext context, Bookmark bookmark, object native_activity) {

 

ActivityFunc

  ActivityFunc

< 令牌 > sevfunc = 新 ActivityFunc < 令牌 >(); sevfunc.Handler =( BpmnEvent )native_activity; ActivityInstance child = context.ScheduleFunc< 令牌 >(sevfunc, this .on_childcompleted, this .on_childfaulted);

<Token> sevfunc = new ActivityFunc<Token>();   sevfunc.Handler = (BpmnEvent)native_activity;  ActivityInstance child = context.ScheduleFunc<Token>(sevfunc, this.on_childcompleted, this.on_childfaulted);

推荐答案

您需要在CacheMetadata中注册ActivityFunc.与其在书签处理程序中创建它,不如在类范围内创建它,并使用元数据在CacheMetadata中注册.AddDelegate-(sevFunc应该是您的活动类的成员) Leon Welicki WF项目经理 You need to register the ActivityFunc in the CacheMetadata. Instead of creating it in your bookmark handler you should create it with class scope and register it in CacheMetadata using metadata.AddDelegate - (sevFunc should be a member of your activity class)Leon WelickiProgram Manager, WF

更多推荐

如何设置活动代表的所有者字段.

本文发布于:2023-11-12 03:49:03,感谢您对本站的认可!
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:所有者   字段   如何设置   代表

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!