到的AsyncTask数组列表值I具有的AsyncTask设置我传递一个Arraystring这样获得通过在doinbackground
ArrayList<String> creds = new ArrayList<String>();
creds.add(string1);
creds.add(string2);
new myasynctask().execute(credentials);
的AsyncTask方法 类myasynctask延伸的AsyncTask,整数,字符串>
DOinbackground
protected String doInBackground(ArrayList<String>... creds)
{ String lol1= creds[0].toString();
String lol2= creds[1].toString();
........rest of the code
}
我得到一个数组i ndex债券异常 如何将两个值传入doinbackground方法并同时获得两者。
您能区分“creds”和“credentials”吗? –