T
TJS
I am trying to list all css files in a directory or its subdirectories, but
cannot get file info. What's missing ?
Dim dir As DirectoryInfo = new DirectoryInfo( server.MapPath("~/css"))
Dim fi As FileSystemInfo
try
For Each fi In dir.GetFileSystemInfos()
If fi.GetType() Is GetType(FileInfo) Then
if instr(fi.name,"css")>0 then
messagex.text &= fi.name & ","
end if
End If
Next
catch
end try
cannot get file info. What's missing ?
Dim dir As DirectoryInfo = new DirectoryInfo( server.MapPath("~/css"))
Dim fi As FileSystemInfo
try
For Each fi In dir.GetFileSystemInfos()
If fi.GetType() Is GetType(FileInfo) Then
if instr(fi.name,"css")>0 then
messagex.text &= fi.name & ","
end if
End If
Next
catch
end try