Simple Open file dialog : OpenFileDialog : GUI Windows Forms C# Examples


C# Examples » GUI Windows Forms » OpenFileDialog »

 

Simple Open file dialog








    
using  System;
using  System.Drawing;
using  System.Windows.Forms;

public  class  OpenFileDialogTest{

    public  static  void  Main()
    {
        OpenFileDialog  dlg=new  OpenFileDialog();

        if(dlg.ShowDialog()  ==  DialogResult.OK)
        {
            MessageBox.Show("You  selected  the  file  "+dlg.FileName);
        }
    }

}
    
   
  
   




HTML code for linking to this page:

Follow Navioo On Twitter

C# Examples

 Navioo GUI Windows Forms
» OpenFileDialog