在我清理和构建应用程序时未声明列表视图,r.java
但它不起作用。我什至删除了r.java
它,它在没有 ListView 的情况下重新生成。
问题
当我android:id="@android:id/listv"
将 XML 文件更改为android:id="@+id/listv"
. 它声明了r.java
但不幸的是出现了许多错误。我认为 Eclipse 正在查看ListView
另一个项目中的另一个,它的 id 列表无论如何这里是 logcat
编辑: 更改 XML 中的声明后
这是日志猫
04-22 17:36:48.253: E/ActivityThread(674): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0cdc8 that was originally bound here
04-22 17:36:48.253: E/ActivityThread(674): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0cdc8 that was originally bound here
04-22 17:36:48.253: E/ActivityThread(674): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
04-22 17:36:48.253: E/ActivityThread(674): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
04-22 17:36:48.253: E/ActivityThread(674): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
04-22 17:36:48.253: E/ActivityThread(674): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
04-22 17:36:48.253: E/ActivityThread(674): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
04-22 17:36:48.253: E/ActivityThread(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
04-22 17:36:48.253: E/ActivityThread(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
04-22 17:36:48.253: E/ActivityThread(674): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
04-22 17:36:48.253: E/ActivityThread(674): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
04-22 17:36:48.253: E/ActivityThread(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
04-22 17:36:48.253: E/ActivityThread(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
04-22 17:36:48.253: E/ActivityThread(674): at android.os.AsyncTask$2.call(AsyncTask.java:287)
04-22 17:36:48.253: E/ActivityThread(674): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
04-22 17:36:48.253: E/ActivityThread(674): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
04-22 17:36:48.253: E/ActivityThread(674): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
04-22 17:36:48.253: E/ActivityThread(674): at java.lang.Thread.run(Thread.java:856)
04-22 17:36:48.304: E/StrictMode(674): null
04-22 17:36:48.304: E/StrictMode(674): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0cdc8 that was originally bound here
04-22 17:36:48.304: E/StrictMode(674): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
04-22 17:36:48.304: E/StrictMode(674): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
04-22 17:36:48.304: E/StrictMode(674): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
04-22 17:36:48.304: E/StrictMode(674): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
04-22 17:36:48.304: E/StrictMode(674): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
04-22 17:36:48.304: E/StrictMode(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
04-22 17:36:48.304: E/StrictMode(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
04-22 17:36:48.304: E/StrictMode(674): at com.android.emailcommon.service.ServiceProxy.test(ServiceProxy.java:191)
04-22 17:36:48.304: E/StrictMode(674): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1850)
04-22 17:36:48.304: E/StrictMode(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
04-22 17:36:48.304: E/StrictMode(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
04-22 17:36:48.304: E/StrictMode(674): at android.os.AsyncTask$2.call(AsyncTask.java:287)
04-22 17:36:48.304: E/StrictMode(674): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
04-22 17:36:48.304: E/StrictMode(674): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
04-22 17:36:48.304: E/StrictMode(674): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
04-22 17:36:48.304: E/StrictMode(674): at java.lang.Thread.run(Thread.java:856)
04-22 17:36:48.304: W/ActivityManager(288): Unbind failed: could not find connection for android.os.BinderProxy@40f77040
04-22 17:36:48.323: E/ActivityThread(674): Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0d680 that was originally bound here
04-22 17:36:48.323: E/ActivityThread(674): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0d680 that was originally bound here
04-22 17:36:48.323: E/ActivityThread(674): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
04-22 17:36:48.323: E/ActivityThread(674): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
04-22 17:36:48.323: E/ActivityThread(674): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
04-22 17:36:48.323: E/ActivityThread(674): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
04-22 17:36:48.323: E/ActivityThread(674): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
04-22 17:36:48.323: E/ActivityThread(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
04-22 17:36:48.323: E/ActivityThread(674): at android.os.AsyncTask$2.call(AsyncTask.java:287)
04-22 17:36:48.323: E/ActivityThread(674): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
04-22 17:36:48.323: E/ActivityThread(674): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
04-22 17:36:48.323: E/ActivityThread(674): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
04-22 17:36:48.323: E/ActivityThread(674): at java.lang.Thread.run(Thread.java:856)
04-22 17:36:48.354: E/StrictMode(674): null
04-22 17:36:48.354: E/StrictMode(674): android.app.ServiceConnectionLeaked: Service com.android.exchange.ExchangeService has leaked ServiceConnection com.android.emailcommon.service.ServiceProxy$ProxyConnection@40d0d680 that was originally bound here
04-22 17:36:48.354: E/StrictMode(674): at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:969)
04-22 17:36:48.354: E/StrictMode(674): at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:863)
04-22 17:36:48.354: E/StrictMode(674): at android.app.ContextImpl.bindService(ContextImpl.java:1418)
04-22 17:36:48.354: E/StrictMode(674): at android.app.ContextImpl.bindService(ContextImpl.java:1407)
04-22 17:36:48.354: E/StrictMode(674): at android.content.ContextWrapper.bindService(ContextWrapper.java:473)
04-22 17:36:48.354: E/StrictMode(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:157)
04-22 17:36:48.354: E/StrictMode(674): at com.android.emailcommon.service.ServiceProxy.setTask(ServiceProxy.java:145)
04-22 17:36:48.354: E/StrictMode(674): at com.android.emailcommon.service.AccountServiceProxy.getDeviceId(AccountServiceProxy.java:116)
04-22 17:36:48.354: E/StrictMode(674): at com.android.exchange.ExchangeService.getDeviceId(ExchangeService.java:1249)
04-22 17:36:48.354: E/StrictMode(674): at com.android.exchange.ExchangeService$7.run(ExchangeService.java:1856)
04-22 17:36:48.354: E/StrictMode(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:551)
04-22 17:36:48.354: E/StrictMode(674): at com.android.emailcommon.utility.Utility$2.doInBackground(Utility.java:549)
04-22 17:36:48.354: E/StrictMode(674): at android.os.AsyncTask$2.call(AsyncTask.java:287)
04-22 17:36:48.354: E/StrictMode(674): at java.util.concurrent.FutureTask.run(FutureTask.java:234)
04-22 17:36:48.354: E/StrictMode(674): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
04-22 17:36:48.354: E/StrictMode(674): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
04-22 17:36:48.354: E/StrictMode(674): at java.lang.Thread.run(Thread.java:856)