I'm trying to make a program that will allow you to browse through your folders (music folders) then when you find one you need to edit. You will double click on it, then all the .mp3 files in that folder will be displayed in a listbox.
Once that is done you will click a button that will say "Rename" and it will rename the mp3 files using the ID Tags in the format of [TRACKNUMBER] - [TRACKTITLE].mp3.
I should be able to tackle the mp3 id tags code by browsing google it's the searching folders code i can't seem to customize to my liking. So could someone please help me out with the searching code?
so far i have this but it just displays all my mp3's in a listbox, instead of me selecting the folders and shit.
Code:
For Each foundfile As String In My.Computer.FileSystem.GetFiles("C:\Users\Covey\Music", FileIO.SearchOption.SearchAllSubDirectories, "*.mp3")
ListBox1.Items.Add(foundfile)
Next
Well, would you be able to show me an example of how to use a Folder Directory Box or something because it's fucking confusing as fuck to me. I'm used to vb6's easy to use shit.
Ok, my aim is to rename all my mp3 files to their correct name, (because i have downloaded them) 90% have extremely shit names like "02_hilltop_hoods_state_of_the_art_2008_chase_that_feeling.mp3" where i would like to change it's name to "02 - Chast That Feeling.mp3" Using the MP3 ID Tags to get the song track and title.
But i would like to be able to select the folders to apply the renaming to it.
I fully accept the fact that .net is far easier/faster/superier to vb6. It's just that i'm extremely shit at it and impatient
I'm not the type of person who learns from following tutorials, i learn things alot faster by dismantling source codes and finding out how it works that way.
Just in case you don't understand, when you open the FolderBrowserDialog, the path information for when you press "OK" is set to FolderBrowserDialog.SelectedPath.
So, for example:
Code:
Dim Path As String
Dim result As DialogResult = fb.ShowDialog()
If(result = DialogResult.OK)
Path = fb.SelectedPath
End If
Just in case you don't understand, when you open the FolderBrowserDialog, the path information for when you press "OK" is set to FolderBrowserDialog.SelectedPath.
So, for example:
Code:
Dim Path As String
Dim result As DialogResult = fb.ShowDialog()
If(result = DialogResult.OK)
Path = fb.SelectedPath
End If
Dim di As New IO.DirectoryInfo("C:\")
Dim aryFi As IO.FileInfo() = di.GetFiles("*.mp3")
Dim fi As IO.FileInfo
For Each fi In aryFi
ListBox1.Items.Add(fi.FullName)
Next
This piece of code will search through the path C:\ (Does not support sub-directories)
It will search for .mp3 files, and add the full path for each item to ListBox1.
Thanks bro, but i've got all that part sorted out. I'm currently trying to disassemble a MP3 project to get the references i need to withdraw the id3 information from the mp3's.
If you're still attempting to do this (i'm guessing you aren't). You could use steamreader to read the mp3 file and do what you did above to display all the mp3 names in a listbox. You could then search for specific characters in the string, use 'split' to split up the string and 'remove' or 'removeat' to remove the specified character. Then use steamwriter to write the mp3 files to a different folder. If you're satisfied then delete all your other songs.