Example #1
0
        // Factory Methods
        public static FolderBrowserDialogEx PrinterBrowser()
        {
            FolderBrowserDialogEx x = new FolderBrowserDialogEx();

            // avoid MBRO comppiler warning when passing _rootFolderLocation as a ref:
            x.BecomePrinterBrowser();
            return(x);
        }
Example #2
0
        private void Dirbutton_Click(object sender, EventArgs e)
        {
            var dlg1 = new FolderBrowserDialogEx();

            dlg1.Description         = "Select a folder:";
            dlg1.ShowNewFolderButton = true;
            dlg1.ShowEditBox         = true;
            //dlg1.NewStyle = false;
            dlg1.SelectedPath          = FSDirectory.Text;
            dlg1.ShowFullPathInEditBox = true;
            dlg1.RootFolder            = System.Environment.SpecialFolder.MyComputer;

            // Show the FolderBrowserDialog.
            DialogResult result = dlg1.ShowDialog();

            if (result == DialogResult.OK)
            {
                FSDirectory.Text = dlg1.SelectedPath;
            }
        }