Suppose you had a file named CurrFiles.txt that had the contents:
c:\folder\file1.m3u
c:\folder\file2.m3u
c:\folder\file3.m3u
c:\folder\file4.m3u
You could put 2 listboxes on a form, along with a button titled Add File.
You could manipulate the files like:
Private Sub Form_Load()
Dim CurrLine As String
Open "C:\CurrFiles.txt" For Input As #1
Do Until EOF(1)
Line Input #1, CurrLine
lsCurrent.AddItem CurrLine
Loop
Close #1
End Sub
Private Sub Form_Unload(Cancel As Integer)
Dim CurrIndex As Integer
Dim CurrFile As String
Open "C:\NewFiles.txt" For Output As #1
For CurrIndex = 0 To (lsNew.ListCount - 1)
CurrFile = lsNew.List(CurrIndex)
Print #1, CurrFile
Next CurrIndex
Close #1
End Sub
Private Sub cmdAdd_Click()
'make sure the user made a selection
If (lsCurrent.ListIndex = -1) Then Exit Sub
lsNew.AddItem lsCurrent.List(lsCurrent.ListIndex)
End Sub
When the form loads, it opens the file "C:\CurrFiles.txt" and reads all the filenames in it into the lsCurrent listbox. When the user clicks the button, it copies whatever is selected in lsCurrent over to the lsNew listbox. When the program is closed (Unlod event), the files in lsNew are written out to NewFiles.txt.
Hope this helps you.
Steve [sig][/sig]