C# DevExpress Windows窗体的文件上载控件

C# DevExpress Windows窗体的文件上载控件,c#,.net,devexpress,devexpress-windows-ui,C#,.net,Devexpress,Devexpress Windows Ui,我是DevExpress WinForms新手,谁能告诉我使用FileUploader控件的简单方法是什么。 我想从“文件”对话框中选择图像并将其添加到PictureEdit 请帮忙!! 提前谢谢 不幸的是,Devexpress不提供文件上载控件(),因此您只能在代码中使用本机文件上载程序 一个简单的代码是 // Create OpenFileDialog Microsoft.Win32.OpenFileDialog dlg = new Microsoft.Win32.OpenF

我是DevExpress WinForms新手,谁能告诉我使用FileUploader控件的简单方法是什么。 我想从“文件”对话框中选择图像并将其添加到PictureEdit

请帮忙!!
提前谢谢

不幸的是,Devexpress不提供文件上载控件(),因此您只能在代码中使用本机文件上载程序

一个简单的代码是

    // Create OpenFileDialog
    Microsoft.Win32.OpenFileDialog dlg = new Microsoft.Win32.OpenFileDialog();
    dlg.Filter = "image Files|*.jpg";

     Nullable<bool> result = dlg.ShowDialog();
     if (result == true)
     {
      this.pictureEdit1.Image = Image.FromFile(dlg.FileName) // Not tested this one
     }
//创建OpenFileDialog
Microsoft.Win32.OpenFileDialog dlg=新的Microsoft.Win32.OpenFileDialog();
dlg.Filter=“图像文件|*.jpg”;
可为空的结果=dlg.ShowDialog();
如果(结果==真)
{
this.pictureEdit1.Image=Image.FromFile(dlg.FileName)//未测试此文件
}
希望这有帮助