E/B4A (12813*12813): java.lang.UnsupportedOperationException
E/B4A (12813*12813): at java.util.AbstractList.remove(AbstractList.java:645)
E/B4A (12813*12813): at anywheresoftware.b4a.objects.collections.List.RemoveAt(List.java:93)
B4X:
Dim files As List
files = File.ListFiles(IdePath)
files.Sort(True)
For i = files.Size - 1 To 0 step -1
If File.IsDirectory(IdePath, files.Get(i)) Then
Log(files.Get(i))
files.RemoveAt(i)
End If
Next
File.ListFiles returns a read-only list. You can't remove items from it.
I believe that sorting will also fail (it may seem to work because the files are already sorted).