Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Listing directories
#2
Hello Covert2String - Welcome to the forum!!

Here is a code that should work for you, not sure if it is exactly what you wanted:

Code:
Dim output As String = ""
        Dim dirinfo As New System.IO.DirectoryInfo(My.Application.Info.DirectoryPath)
        Dim allfileinfo() As System.IO.FileInfo = dirinfo.GetFiles("*", IO.SearchOption.AllDirectories)
        For Each item In allfileinfo
            If item.DirectoryName = My.Application.Info.DirectoryPath Then
                output = output + item.Name + vbNewLine
            Else
                output = output + item.DirectoryName + item.Name + vbNewLine
            End If
        Next
My Blog | My Setup | My Videos | Have a wonderful day.


Messages In This Thread
Listing directories - by Covert2String - 08-19-2011, 06:44 PM
Re: Listing directories - by brandonio21_phpbb3_import2 - 08-19-2011, 08:18 PM
Re: Listing directories - by Covert2String - 08-20-2011, 02:59 AM
Re: Listing directories - by Covert2String - 08-20-2011, 10:15 AM
Re: Listing directories - by Covert2String - 08-20-2011, 10:48 AM
Re: Listing directories - by Covert2String - 08-20-2011, 02:41 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)