This is a problem I am currently having. Here is my code:
String[] sArray = new String[maxEntries*2];
for (int i = 0; i != (maxEntries*2); i++)
{
sArray[i] = lines[i].split(",");
}
error: incompatible types: String[] cannot be converted to String
sArray[i] = lines[i].split(",");
^
sArray
is an array of String, thus sArray[i]
is a String.
The split(String str)
method returns an array.
You are trying to give an array value to a string variable. sArray must be an array of String arrays