提供了数据对话框 [英] Providing data to dialog

查看:137
本文介绍了提供了数据对话框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

静态类的ControlCenter ,这在时间间隔与外部系统进行通信。
对于每一个问题和放大器;回答外部系统我的的ControlCenter 引发事件提供状态信息的用户界面层。即使通信失败,事件错误mesage升高。
现在结果的问题:结果
如果有一些通信错误,我想表现出的对话框模式,以便用户只能使用此互动形式或对话框显示UI项。
结果即使出现的ControlCenter和UI层之间的误差,通讯仍在继续,我想提供给显示对话框实际数据为例的尝试重新连接.... 3试20你想杀人的服务?
结果我希望能够隐藏自己从用户点击或编程从其父形式(顶部UI层)。

I have static class ControlCenter, which in time-intervals communicates with external system. For every single question&answer to external system my ControlCenter raises event which provides status information UI layer. Even if communication fails, event with error mesage is raised.
Now problem:
If there are some communication errors i want show form or dialog box in dialog mode so user can interact only with this showed UI item.
Even if there is an error, communication between ControlCenter and UI layer continues and I want provide to showed dialog actual data for exampl "Trying to reconnect....3rd try from 20 do you want kill service?"
I want be able hide this dialog form from itself by user click or programatically from its parent form (top ui layer).

我试图创建自己的消费形式从其父形式和展示 MyForm.ShowDialog()数据事件;但之后的ShowDialog()UIlayer等待与对话用户操作。

I was trying create my own Form consuming event with data from its parent form and showing MyForm.ShowDialog(); but after showdialog() UIlayer waits on user action with dialog.

你知道请了一些演练对于这样的背景下?
结果非常感谢你。

Do you know pls some walkthrough for this context?
Thank you very much.

推荐答案

<一个href=\"http://stackoverflow.com/questions/2435752/open-a-second-winform-asynchronously-but-still-behave-as-a-child-to-the-parent-f\">This问题是你的差不多,具有良好的回答一个样本。它归结为使用的BackgroundWorker 类检索所需的信息。

This question is very similar to yours and has a good answer with a sample. It boils down to using BackgroundWorker class for retrieving needed information.

这篇关于提供了数据对话框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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