コード例 #1
0
 private void button1_Click(object sender, EventArgs e)
 {
     FolderBrowserDialogEx fb = new FolderBrowserDialogEx();
     fb.ShowEditbox = true;
     //fb.RootFolder =
     if (fb.ShowDialog(this) == DialogResult.OK)
     {
         this.textBox1.Text = fb.SelectedPath;
     }
 }
コード例 #2
0
 private void button2_Click(object sender, EventArgs e)
 {
     FolderBrowserDialogEx fd = new FolderBrowserDialogEx();
     fd.ShowEditbox = true;
     //fd.DefaultExt = "ArcGIS File Geodatabase(*.gdb)|*.gdb";
     if (fd.ShowDialog(this) == DialogResult.OK)
     {
         this.textBox2.Text = fd.SelectedPath;
     }
 }
コード例 #3
0
 public InitData(FolderBrowserDialogEx dlg, IntPtr hParent)
 {
     // We need to make copies of these values from the dialog.
     // I tried passing the dlg obj itself in this struct, but Windows will barf after repeated invocations.
     Title               = dlg.Title;
     InitialPath         = dlg.SelectedPath;
     ShowNewFolderButton = dlg.ShowNewFolderButton;
     ShowEditbox         = dlg.ShowEditbox;
     StartPosition       = dlg.StartPosition;
     this.hParent        = hParent;
 }
コード例 #4
0
 public InitData(FolderBrowserDialogEx dlg, IntPtr hParent)
 {
     // We need to make copies of these values from the dialog.
     // I tried passing the dlg obj itself in this struct, but Windows will barf after repeated invocations.
     this.Title = dlg.Title;
     this.InitialPath = dlg.SelectedPath;
     this.ShowNewFolderButton = dlg.ShowNewFolderButton;
     this.ShowEditbox = dlg.ShowEditbox;
     this.StartPosition = dlg.StartPosition;
     this.hParent = hParent;
 }