Good day!
Please see the below cobbled together snippit:
The problem I'm having is whenever I try to do a favs.Add() or favs.RemoveAt(), I get a java exception of "UnsupportedOperationException".
I've tried all the variations of these methods that I can come up with...
Any Ideas?
Oh...Main.FavPath is a valid path and does work. It equates to File.DirDefaultExternal & "/Favorites"
Also...Might there be a way to get File.ListFiles to get only a certain file type? *.txt for instance.
THANKS MUCH!!!!
Please see the below cobbled together snippit:
B4X:
Dim favs As List
favs.Initialize
favs = File.ListFiles(Main.FavPath)
Dim Tst as string = "This is a test"
favs.Add(Tst)
For i = 0 to favs.Size
If favs.Get(i) = Tst Then
favs.RemoveAt(i)
End If
Next
...
The problem I'm having is whenever I try to do a favs.Add() or favs.RemoveAt(), I get a java exception of "UnsupportedOperationException".
I've tried all the variations of these methods that I can come up with...
Any Ideas?
Oh...Main.FavPath is a valid path and does work. It equates to File.DirDefaultExternal & "/Favorites"
Also...Might there be a way to get File.ListFiles to get only a certain file type? *.txt for instance.
THANKS MUCH!!!!