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);
}
}
}