本文介绍了如何使用C#检查任何WPF / Windows应用程序中任何层/组件的活动性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

我们是否有办法检查或监控任何WPF应用程序中任何层或组件的活动性?我听说过WatchDog机制用于此目的但无法获得任何正确的信息。



我的情景 -



ComponentOne(ClassLibrary)

||

||在ComponentTwo中使用的引用

V

ComponetTwo(ClassLibrary)

||

||在ComponentThree中使用的引用

V

ComponentThree(.exe / view)



在视图中我想要显示上面两个组件的健康状态,如Active - 如果一切正常,死 - 如果任何线程被中止等等。

我们需要引入一种机制,GUI知道接口是否仍然完好/活着/回应等



我尝试过:



阅读关于WatchDog,但没有运气

Hello,
Do we have any way to check or monitor the activeness of any layer or component in any WPF application ? I heard about WatchDog mechanism to use for this purpose but couldn't get any proper information.

My Scenario -

ComponentOne (ClassLibrary)
||
|| reference being used in ComponentTwo
V
ComponetTwo (ClassLibrary)
||
|| reference being used in ComponentThree
V
ComponentThree (.exe/view)

On view i want to show the health of above two component something like Active-if everything is fine, Dead- if any Thread is aborted etc.
we need to introduce a mechanism that the GUI knows if the Interface is still intact/alive/responding etc.

What I have tried:

Read about WatchDog but no luck

推荐答案


这篇关于如何使用C#检查任何WPF / Windows应用程序中任何层/组件的活动性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-02 16:13