UI 中的更改不会触发任何事件
我正在开发一个项目,我们使用 Infragistics 作为第三方控制库。我们没有提供该项目的任何文档,我唯一知道的是他们使用了 MVP 设计模式。现在我正在尝试根据给我的任务调试应用程序。
我有一个自定义网格(主要来自 Infragistics),它具有三列“ColA、ColB、ColC”。 ColB 和 ColC 有组合框。 ColB 和 ColC 已绑定到数据源。当我更改 ColB 组合框中的选定项目时,根据 ColB 中的选择,ColC 组合集合会自我完善(根据 ColB 中的值删除一些项目)。这里我需要根据 ColB 选择的值更改 ColC 集合细化中的一些逻辑。但我无法这样做,因为我不确定改进是在哪里进行的。我尝试放置断点,但是在更改 ColB 中的值时没有事件触发,因此我不知道与细化相关的代码。
我知道这个问题是针对我的项目的,但我的问题是,除了断点之外,有没有什么方法可以根据我在 UI 中采取的操作来获取代码?或者在这种情况下我应该采取什么方法?我不太擅长调试工具。
谢谢。
I am working on a project, and we are using Infragistics as a third party control library. We have not provided with any documentation of the project and only thing I know is they have used MVP design pattern. Now I am trying to debug the application based on the task given to me.
I have a custom grid (mostly from Infragistics) and it has three columns "ColA, ColB, ColC". ColB and ColC have comboboxes. ColB and ColC already are bind to a datasource. When I change the selected item in the ColB combobox, based on the selection in ColB, ColC combo collection refines itself(removes few items based on the value in ColB). Here I need to change some logic in the collection refinement for ColC based on the ColB selected value. But I am not able to as I am not sure where the refinement is taking place. I tried placing the breakpoints, but there is no event triggering while changing the value in ColB and thus I dont know the codes related to refinement.
I know the question is specific to my project, but what my question is that is there any way to get to the codes based on the action taken by me in the UI apart from breakpoints? Or is there any approach I should be following in this situation? I am not very good in debugging tools.
Thank You.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
很难说清楚使用什么事件来更新单元格中的组合框。如果您有源代码,请检查这些 UltraGrid 事件以获取细化代码。
colB 更改后 触发的事件:
之前 用户将看到列 colC 的展开组合框触发的事件:
还可以尝试一个小测试。例如,colB 和 ColC 之间有以下依赖关系:
设置 colB=B1 和 colC=C1b。现在切换到另一行,返回到该行并将 colB 更改为 B2。如果 colC 中的值发生更改,那么您应该查看单元格更改后触发的事件。如果没有发生任何事情 - 您的代码可能位于两组事件中。
您也可以尝试在代码中搜索术语 ValueList - 该代码可能使用此单元格属性。
It is hard to say what event is used to update combobox in a cell. If yo have sources, check these UltraGrid events for refinement code.
Events fired after colB changed:
Events fired just before user will see an expanded combobox of column colC:
Also try a small test. For example you have these dependencies between colB and ColC:
Set colB=B1 and colC=C1b. Now switch to another row, come back to this row and change colB to B2. If value in colC is changed, then you should look in events fired after cell change. If nothing happened - your code may be in both groups of events.
Also you may try to search your code for a term ValueList - that code likely use this cell property.
我已经深入研究了代码,看看它实际上是如何工作的。对于我们的项目,所有控件都是在不同解决方案中一起创建的自定义控件。所有这些功能都是为不同类型的控件定义的,这就是为什么在更改选择时没有触发事件的原因。但是,如果您更改自定义控件解决方案中的某些内容,则该类型的所有控件都会受到影响。因此,他们甚至给这些自定义控件附加了一个计数器事件。我必须为此努力。我知道这是高度项目特定的查询和解决方案。
I have gone deep into the code to see how it actually works. For our project, all the controls are the custom controls that are created in a different solution all together. All these functionality are defined there for different kind of controls and that is the reason why no event was triggering while changing the selection. But if you change something in the custom control solution all controls of that type will be affected. For that reason they have they have even given a counter event attached to these custom controls. I will have to work on that. I know this was highly project specific query and as well as solution.