multidiskscanner IncludeList property
TDiskScanList Example
Return to Introduction  Previous page  Next page
Applies to
dcMultiDiskScanner component.  

property IncludeList: TDiskScanList// TList  

The IncludeList property is the list of searching rules that defines the locations and searching masks which you would like to include to search results.  
You can set the including rules either at design and run-time of your application.  
The IncludeList property has the TDiskScanList type. To add the new rule to IncludeList at run-time - call IncludeList.AddPath(LocationIncludeSubfolders) method. To clear the list - call IncludeList.Clear method. Please see an example for more details.  

If you would like to find files in certain locations, you MUST specify the path information. In example:  
IncludeList.AddPath('C:\My Bitmaps\*.bmp', True);  
tip Specifying the searching rules without path information, or with incomplete path information, will be considered as try to search within current working directory, and/or on current disk. However, the path will be automatically fixed, accordingly to current working disk/directory, and the OnFileFound event will return files with complete path information.  
·For example, you have specified the "*.bmp" to the IncludeList:  
IncludeList.AddPath('*.bmp', True); // no path specified  
This means that you would like to found ALL bitmaps within current working directory + within all its subdirectories.  
·In case if you have specified the disk, but not pointed to the folder where to search files, in example, "D:*.*", the dcMultiDiskScanner will search files in current directory on specified disk:  
IncludeList.AddPath('D:*.bmp', False); // disk without path  
·You can also specify folder where to search files but not point the disk. For example, "\My Bitmaps\*.bmp". The dcMultiDiskScanner will try to search files in "\My Bitmaps\" directory on current disk.  
IncludeList.AddPath('\My Bitmaps\*.bmp', False); // path without disk  
iiwarning If you have specified the non-existing folder, the OnFolderNotExist event will occurs to inform you about impossibility to search files in this folder.  

See also
ExcludeList property;  
OnFileFound and OnFolderNotExist event.