DirectoryInfo ....

thrillos

New member
Joined
Nov 27, 2007
Messages
4
Programming Experience
3-5
Hi guys,

Can anyone tell me how can i determine if a directory in my hard disk satisfies a specific condition?

All i want to do is determine whether there are pdf files in a folder or not...

Thanks in advance!
 
If IO.Directory.GetFiles("the folder path", "*.pdf").Length > 0 Then you got it. There is also an overload of GetFiles method that includes all subdirs in search.
 
Back
Top