R – FolderBrowserDialog takes eons to list the subfolders of a folder located in an USB drive

folderbrowserdialognetperformanceusb

Using a FolderBrowserDialog in a USB Drive takes several minutes to offer subfolders (independently of how many subfolders are there). Whereas Windows Explorer does show them in a relatively quick manner.

Code I'm using is:

if (folderBrowserDialog1.ShowDialog() == DialogResult.OK) {
  //grab value
}

I navigate to the USB drive, and click on a folder in the root to have to wait lots of time.

This is .NET 2.0 SP1 (32 bits executable) on Windows Server 2003 x64

Is there any known cause for this? Why is it taking so much longer than Windows Explorer?

A cursory Google search seems to indicate I'm alone in this. I've found references to it crashing on 64 bit systems, but I don't actually get a crash, if I wait the several minutes it ends up working.

Best Answer

HAve you tried to debug windows explorer wich system call is he reffering when opening subfolders ? And do the same for your application ? Either there is a difference in system call or is doing something more. Or last case it fails many times and only some times succedes.

Related Topic