- Home /
Problem String.split() Function on Android
Hi, all! i am running this code in desktop and works fine, but after i run in android, the code doesn't work and stuck in "splitArr = x[i].Split(',');" . and this is the code :
void splitDataRaw(List<string> x){
for(int i=0; i<x.Count; i++){
splitArr = x[i].Split(',');
tanggal.Add(int.Parse(splitArr[0]));
bulan.Add(int.Parse(splitArr[1]));
tahun.Add(int.Parse(splitArr[2]));
jam.Add(int.Parse(splitArr[3]));
menit.Add(int.Parse(splitArr[4]));
detik.Add(int.Parse(splitArr[5]));
harga.Add(int.Parse(splitArr[6]));
kendaraan.Add(splitArr[7]);
status.Add(splitArr[8]);
kategori.Add(splitArr[9]);
}
}
There's nothing in that code that looks like it might result in a platform-specific bug. Could be something to do with the data co$$anonymous$$g into it.
$$anonymous$$ore importantly, I can't figure out what you mean by it being "stuck" in that line of code. If it's generating an error, let us know what the error says. If not, let us know what makes you think that bit of code is relevant.
Your answer
![](https://koobas.hobune.stream/wayback/20220612055114im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
How can I include a C++ dll in the .apk file 3 Answers
How to Code for android phone always stay awake? 2 Answers
Manually install build targets 0 Answers
NoSuchMethodError calling android method 2 Answers
Swipe menu, problem! 0 Answers