在不使用代码的情况下访问外部事件Args。 [英] Accessing External Event Args without using code.

查看:64
本文介绍了在不使用代码的情况下访问外部事件Args。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用HandleExternalEventActivity来处理一个事件,其参数包含我感兴趣的一些信息,并且工作流程需要决定下一步该做什么。

在Bruce Bukovics的书中(第7章)他建议了几种使用这些数据的方法:

- 在工作流本身上创建一个属性,将事件args绑定到。
- 为Invoked事件添加代码处理程序HandleExternalEventActivity的内容。

但是,我希望能够在不向工作流添加代码的情况下执行此操作 - 因此它只是xaml。

有没有办法访问事件args并控制工作流而不添加代码,也许使用声明性规则条件?我还没有找到一种方法来获得这些论点 - 它们似乎不是活动的属性(通过mechansim它们出现在设计师中的什么?)。

在此先感谢。

I'm using HandleExternalEventActivity to handle an event whose arguments contain some information I am interested in, and which is required for the workflow to decide what to do next.

In Bruce Bukovics' book (chapter 7) he suggests a couple of ways to use this data:

- Create a property on the workflow itself to bind the event args to.
- Add a code handler to the Invoked event of the HandleExternalEventActivity.

However, I would like to be able to do this without adding code to the workflow - so it is xaml only.

Is there a way to access the event args and control the workflow without adding code, perhaps using a declarative rule condition? I haven't yet been able to find a way to get to the arguments - they don't seem to be a property of the activity (by what mechansim do they appear in the designer?).

Thanks in advance.

推荐答案

我认为没有代码可以使用参数。

您是否可以编写一个客户活动来包含上述逻辑(以便只引用您的自定义活动并且它仅变为xaml)?

感谢
I don't think it is possible to consume the arguments without code.

Can you write a custome activity to wrap the above logic (so that only your custom activity is referenced and it becomes xaml only)?

Thanks

Yuan Hu


这篇关于在不使用代码的情况下访问外部事件Args。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆