Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Option Explicit
- Type plikwindows
- nazwa As String * 60
- rozszerzenie As String * 10
- End Type
- Sub usun()
- Dim row As Integer, cell
- For row = 3 To 5000
- cell = Cells(row, 1)
- If InStr(cell, "Directory") <> 0 Or Len(cell) <= 3 And Len(cell) >= 1 Or IsNumeric(Left(cell, 1)) Then
- Cells(row, 1) = ""
- End If
- Next
- End Sub
- Sub zapisz()
- Dim name As String, i As Integer, now As String
- name = Application.GetSaveAsFilename
- Open name For Output As #1
- For i = 3 To 5000
- now = Cells(i, 1)
- If Not now = "" Then Print #1, now
- Next
- Close #1
- MsgBox "gotowe"
- End Sub
- Sub zlicz()
- Dim row As Integer, cell, dlls As Integer, exes As Integer, op As Integer
- For row = 3 To 5000
- cell = Cells(row, 1)
- If cell Like "*.dll" Then
- dlls = dlls + 1
- ElseIf cell Like "*.exe" Then
- exes = exes + 1
- ElseIf cell Like "?o*.??p*" Then
- op = op + 1
- End If
- Next
- Cells(3, 3) = dlls
- Cells(3, 4) = exes
- Cells(3, 5) = op
- End Sub
- Sub zapisz_dostep_swobodny()
- Dim name As String, i As Integer, pliki As plikwindows, cell, row As Integer, leng As Integer, rozszerzenie As String
- name = Application.GetSaveAsFilename
- i = 1
- Open name For Random As #1 Len = Len(pliki)
- For row = 3 To 5000
- cell = Cells(row, 1)
- If cell <> "" And InStr(cell, ".") <> 0 Then
- If InStr(cell, "\") = 0 Then
- rozszerzenie = Right(cell, InStr(StrReverse(cell), "."))
- If rozszerzenie = ".exe" Or rozszerzenie = ".ini" Or rozszerzenie = ".xml" Or rozszerzenie = ".JSON" Or rozszerzenie = ".bin" Or rozszerzenie = ".txt" Or rozszerzenie = ".dll" Or rozszerzenie = ".log" Or rozszerzenie = ".prx" Or rozszerzenie = ".ecf" Or rozszerzenie = ".cab" Or rozszerzenie = ".hve" Or rozszerzenie = ".png" Or rozszerzenie = ".sdb" Or rozszerzenie = ".mui" Or rozszerzenie = ".nlp" Or rozszerzenie = ".config" Or rozszerzenie = ".resources" Then
- With pliki
- .nazwa = Left(cell, Len(cell) - InStr(StrReverse(cell), "."))
- .rozszerzenie = rozszerzenie
- End With
- Put #1, i, pliki
- i = i + 1
- End If
- End If
- End If
- Next
- Close #1
- MsgBox "gotowe"
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement