I am using a form with just LMDShellFolder, LMDShellTree, and LMDShellList. LMDShellFolder.ChDir takes ages to display disconnected network drives in the LMDShellTree/LMDShellList. How can I hide or exclude such drives from the display? Or is there a different approach?
1) I've added new IsSlow property to TLMDShellItem class (SFGAO_ISSLOW). It can be theoretically used for filtering, but it seems that it does not set for my network drives.
2) I've changed the way, a tree node detects, whether it has children (to show [+] expand button). Now it based on SFGAO_HASSUBFOLDER attribute, which should not block the program in case of inaccessible network drives, according to MS documentation. However, this does not solve the issue completely.
3) I was unable to find good way to filtering out network drives, the only was, which worked for me is to use tree or list OnFilterItem event and set Filtered property to True as follows:
The first impression is good. After mapping a new network drive, it appeared in neither the tree view nor the list. Isn't there some way to configure this so that it applies only to disconnected drives??
Comments