private void btnSave_Click(object sender, EventArgs e) {
OpenFileDialog dialog = new OpenFileDialog();
dialog.Title = "选择要导入的Excel文件";
dialog.Filter = "Excel files (*.xls)|*.xls";
if (dialog.ShowDialog() == DialogResult.OK) {
Loading loading = App.Resolve<Loading>(new ParameterOverride("Message", "Loading ..."));
App.MainForm.ShowView(loading);
String fileName = dialog.FileName;
this.Presenter.ImportFuncList(fileName);
this.Presenter.LoadFuncList();
//loading.FindForm().Close();
}
}
我想在导入过程中弹出一个新的loading窗口,上面有一个DevExpress控件
progressPanel,自带旋转图片,但是当我点击确定的时候,弹出的窗口上图片不转,只有
String fileName = dialog.FileName;
this.Presenter.ImportFuncList(fileName);
this.Presenter.LoadFuncList();
这三部全部执行完,主窗口刷新后那个控件上的图片才动,请问这是不是线程问题,我该如何新开一个线程让图片一开始就转起来??
OpenFileDialog dialog = new OpenFileDialog();
dialog.Title = "选择要导入的Excel文件";
dialog.Filter = "Excel files (*.xls)|*.xls";
if (dialog.ShowDialog() == DialogResult.OK) {
Loading loading = App.Resolve<Loading>(new ParameterOverride("Message", "Loading ..."));
App.MainForm.ShowView(loading);
String fileName = dialog.FileName;
this.Presenter.ImportFuncList(fileName);
this.Presenter.LoadFuncList();
//loading.FindForm().Close();
}
}
我想在导入过程中弹出一个新的loading窗口,上面有一个DevExpress控件
progressPanel,自带旋转图片,但是当我点击确定的时候,弹出的窗口上图片不转,只有
String fileName = dialog.FileName;
this.Presenter.ImportFuncList(fileName);
this.Presenter.LoadFuncList();
这三部全部执行完,主窗口刷新后那个控件上的图片才动,请问这是不是线程问题,我该如何新开一个线程让图片一开始就转起来??
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货