C cjolly Member Licensed User Longtime User Nov 30, 2012 #1 I have this piece of code: Dim ListaLOG As List ListaLOG.Initialize ListaLOG = File.Listfiles("/data/data/totalrecall.control/files/") For i = 0 To ListaLOG.Size -1 <<<<< in this line point this error >>>>> java.lang.RuntimeException: Object should first be initialized (List). Upload_File = ListaLOG.Get(i) ... This is a bug or should not be used in this way If I use File.Dir..... works ok, but if I use "/data/data/totalrecall.control/files/" shows me the error indicated
I have this piece of code: Dim ListaLOG As List ListaLOG.Initialize ListaLOG = File.Listfiles("/data/data/totalrecall.control/files/") For i = 0 To ListaLOG.Size -1 <<<<< in this line point this error >>>>> java.lang.RuntimeException: Object should first be initialized (List). Upload_File = ListaLOG.Get(i) ... This is a bug or should not be used in this way If I use File.Dir..... works ok, but if I use "/data/data/totalrecall.control/files/" shows me the error indicated
thedesolatesoul Expert Licensed User Longtime User Nov 30, 2012 #2 Because that is a system android folder not accessable to your app.
Erel B4X founder Staff member Licensed User Longtime User Dec 2, 2012 #3 You can test List.IsInitialized before you access the list items.