Dim path As String = "C:\FTP\Backup\" Dim i As Integer Dim FileCount As Integer = IO.Directory.GetFiles(path, "*.jpg").Length 'count the number of existing file with specific ext. in a path Dim fileName(FileCount - 1) As String 'represent as array Dim fileInfo As New FileInfo(path) If FileCount <> 0 Then For i = 1 To FileCount fileName(i) = fileInfo.Name 'array will hold the file name from file info Next End If
Dim matching As String() = Directory.GetFiles(path, "*.jpg")
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)