【发布时间】:2014-05-12 09:50:15
【问题描述】:
@Override
protected List<String> doInBackground(String... urls) {
JPOSeReprintPreview.this.runOnUiThread(new Runnable() {
@Override
public void run() {
myReceipt reprintReceipt = new myReceipt ();
lstOutput= reprintReceipt.saveReprint(muncID);
if(lstOutput.size()==0 || lstOutput==null){
System.out.println("Failed Sending data");
}
}
});
return lstOutput;
}
@Override
protected void onPostExecute(List<String> response) {
if(response.get(0).equals("SUCCESS")){ } }
我的列表 lstOutput 在访问 onPostExecute 时重置为 null。我的 onPostExecute 出现无效索引异常。为什么会发生这种情况?
【问题讨论】:
标签: java android asynchronous android-asynctask