Hi
Ich hatte diesen COde schon mal in ei Programm eingebaut, und jetzt möchte ich ihn für die Öffentlichkeit zugänglich machen.
Der Code erkennt euern Firefox und Google Chrome Cache und schickt ihn an eine ListBox
Grüße
Ich hatte diesen COde schon mal in ei Programm eingebaut, und jetzt möchte ich ihn für die Öffentlichkeit zugänglich machen.
Der Code erkennt euern Firefox und Google Chrome Cache und schickt ihn an eine ListBox
VB.NET-Quellcode
- Private Sub CacheSuchen(ByVal liste As ListBox)
- Dim LocalApplicationData As String = Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData)
- Dim FirefoxPfad As String = LocalApplicationData & "\Mozilla\Firefox\Profiles\"
- Dim FirefoxCache As String = ""
- Dim ChromeCache As String = LocalApplicationData & "\Google\Chrome\User Data\Default\Cache"
- If IO.Directory.Exists(FirefoxPfad) = True Then
- Dim profiles() As String = IO.Directory.GetDirectories(FirefoxPfad)
- Dim profilelist As New ListBox
- For Each i As String In profiles
- Dim profiledir As String = IO.Path.GetFileName(i)
- profilelist.Items.Add(profiledir)
- For j = 0 To profilelist.Items.Count - 1
- FirefoxCache = FirefoxPfad & profilelist.Items.Item(j) & "\Cache"
- Next
- Next i
- If Not liste.Items.Contains(FirefoxCache) Then
- liste.Items.Add(FirefoxCache)
- End If
- Else : End If
- If IO.Directory.Exists(ChromeCache) = True Then
- If Not liste.Items.Contains(ChromeCache) Then
- liste.Items.Add(ChromeCache)
- End If
- Else : End If
- End Sub
Grüße