1.
Public Sub LoadCookies(ByVal lst As ListBox)
2.
lst.Items.Clear()
3.
Dim di As New DirectoryInfo(System.Environment.GetFolderPath(Environment.SpecialFolder.Cookies))
4.
For Each File As FileInfo In di.GetFiles
5.
If File.Extension = ".txt" Then
6.
Dim re As String = GetFileName(File.Name.ToString)
7.
frmMain.ListCookies.Items.Add(re)
8.
End If
9.
Next
10.
frmMain.Label1.Text = String.Format("Cookies Folder - {0} Items", frmMain.ListCookies.Items.Count)
11.
End Sub