I am glad you felt the need to mention me in the first post, however with other people it can be a burden to them. Please do not mention someone in the first post again.
To return a list you would actually do…
/** Do not use a wildcard for the YailList (such as com.google.appinventor.components.runtime.util.*), instead reference the class otherwise it will not work **/
import com.google.appinventor.components.runtime.util.YailList;
...
@SimpleFunction
public YailList ReturnListExample() {
YailList myList = new YailList();
myList.addItem("String");
return myList;
}
If doing myList.addItem("String") on that example gives you an error, then do the following instead…
import java.util.ArrayList;
import java.util.List;
...
@SimpleFunction
public List ReturnListExample() {
List myList = new ArrayList();
myList.addItem("String");
return myList;
}
Now if the previous example didn’t work (which it should as from the code from my extensions source), the last try would be…
import java.util.ArrayList;
...
@SimpleFunction
public ArrayList ReturnListExample() {
ArrayList myList = new ArrayList();
myList.addItem("String");
return myList;
}
But, try the first 2 examples and see where you get before resorting to the final solution!