shows browsing for a file
/* Mastering Visual C# .NET by Jason Price, Mike Gunderloy Publisher: Sybex; ISBN: 0782129110 */ /* Example15_1.cs shows browsing for a file */ using System; using System.Windows.Forms; public class Example15_1 { [STAThread] public static void Main() { // create and show an open file dialog OpenFileDialog dlgOpen = new OpenFileDialog(); if (dlgOpen.ShowDialog() == DialogResult.OK) { Console.Write(dlgOpen.FileName); } } }