Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Referencia: https://www.youtube.com/watch?v=C_IHyLdsl_I
- Para cargar los archivos:
- Dim Folder As New FolderBrowserDialog
- Folder.Description = "DESCRIPCION AQUI"
- Folder.ShowNewFolderButton = False
- Folder.SelectedPath = "C:\"
- Try
- For Each Archivo As String In My.Computer.FileSystem.GetFiles(
- "C:\",
- FileIO.SearchOption.SearchAllSubDirectories,
- "*.Formatos", "*.AQUI")
- ListBox1.Items.Add(Archivo)
- Next
- Catch oe As Exception
- MsgBox(oe.Message, MsgBoxStyle.Critical, "El Codigo es como tu Vida, Llena de Errores xD")
- End Try
- Para eliminar un archivo:
- If e.KeyCode = Keys.Delete And ListBox1.Items.Count 0 And ListBox1.SelectedIndex -1 Then
- Dim a As Integer = ListBox1.SelectedIndex
- ListBox1.SelectedIndex = a
- ListBox1.Items.RemoveAt(ListBox1.SelectedIndex)
- End If
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement