I am trying to open the download's folder programmatically. But, I keep getting ActivityNotFoundException. I have seen various questions on this on StackOverflow, tried most of them, but nothing worked till now. Here is my code below
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setData(Uri.parse(downloadDirectoryPath));
startActivity(intent);
AndroidManifest.xml - related code
<activity
android:name="com.xx.xxx.videowebview.VideoWebViewActivity"
android:configChanges="orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
android:hardwareAccelerated="true"
android:label="#string/app_name"
android:theme="#style/custom_theme" >
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
I think I have set the required things in manifest too, but, I still keep getting the Exception.
I have a download button in VideoWebViewActivity, when clicked, downloads a file and then has to open the download folder on the device. Is setting, category to DEFAULT as above, correct? or should I be using a new activity(I don't really need any other activity, so should I be using a dummy activity? Doesn't sound right...)?
Here is my LogCat...
03-28 15:17:37.349: E/AndroidRuntime(15791): FATAL EXCEPTION: main
03-28 15:17:37.349: E/AndroidRuntime(15791): android.content.ActivityNotFoundException: No Activity found to handle Intent { act=android.intent.action.VIEW dat=/mnt/sdcard/download/ }
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1409)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.app.Instrumentation.execStartActivity(Instrumentation.java:1379)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.app.Activity.startActivityForResult(Activity.java:2827)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.app.Activity.startActivity(Activity.java:2933)
03-28 15:17:37.349: E/AndroidRuntime(15791): at com.xx.xxx.videowebview.VideoWebViewActivity$DownloadFile.onPostExecute(VideoWebViewActivity.java:442)
03-28 15:17:37.349: E/AndroidRuntime(15791): at com.xx.xxx.videowebview.VideoWebViewActivity$DownloadFile.onPostExecute(VideoWebViewActivity.java:1)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.os.AsyncTask.finish(AsyncTask.java:417)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.os.AsyncTask.access$300(AsyncTask.java:127)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.os.AsyncTask$InternalHandler.handleMessage(AsyncTask.java:429)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.os.Handler.dispatchMessage(Handler.java:99)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.os.Looper.loop(Looper.java:130)
03-28 15:17:37.349: E/AndroidRuntime(15791): at android.app.ActivityThread.main(ActivityThread.java:3687)
03-28 15:17:37.349: E/AndroidRuntime(15791): at java.lang.reflect.Method.invokeNative(Native Method)
03-28 15:17:37.349: E/AndroidRuntime(15791): at java.lang.reflect.Method.invoke(Method.java:507)
03-28 15:17:37.349: E/AndroidRuntime(15791): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:878)
03-28 15:17:37.349: E/AndroidRuntime(15791): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:636)
03-28 15:17:37.349: E/AndroidRuntime(15791): at dalvik.system.NativeStart.main(Native Method)
I haven't yet figured it out, but, for now, I am directly opening the file that I downloaded using the below code...
File file = new File(path);
Uri uri_path = Uri.fromFile(file);
String mimeType = MimeTypeMap.getSingleton().getMimeTypeFromExtension
(MimeTypeMap.getFileExtensionFromUrl(path));
Intent intent = new Intent(android.content.Intent.ACTION_VIEW);
intent.setType(mimeType);
intent.setDataAndType(uri_path, mimeType);
startActivity(intent);
path = the path of the FILE(not directory) that you want to open.
Will update the answer, if I get to open the directory successfully.
Related
I am updating my fragment from sqlite when getting push notification from server when i was on same fragment it's update. But when i was on another activity and getting push notification my application is crashing.
Here is my exception :
03-28 22:18:03.302: E/AndroidRuntime(17631): FATAL EXCEPTION: main
03-28 22:18:03.302: E/AndroidRuntime(17631): Process: com.newt.vdsi.driver, PID: 17631
03-28 22:18:03.302: E/AndroidRuntime(17631): java.lang.IllegalStateException: Can not perform this action after onSaveInstanceState
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.app.FragmentManagerImpl.checkStateLoss(FragmentManager.java:1360)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.app.FragmentManagerImpl.enqueueAction(FragmentManager.java:1378)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.app.BackStackRecord.commitInternal(BackStackRecord.java:595)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.app.BackStackRecord.commit(BackStackRecord.java:574)
03-28 22:18:03.302: E/AndroidRuntime(17631): at com.newt.vdsi.driver.Home$1.onReceive(Home.java:517)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.content.LocalBroadcastManager.executePendingBroadcasts(LocalBroadcastManager.java:297)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.content.LocalBroadcastManager.access$000(LocalBroadcastManager.java:46)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.support.v4.content.LocalBroadcastManager$1.handleMessage(LocalBroadcastManager.java:116)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.os.Handler.dispatchMessage(Handler.java:102)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.os.Looper.loop(Looper.java:136)
03-28 22:18:03.302: E/AndroidRuntime(17631): at android.app.ActivityThread.main(ActivityThread.java:5086)
03-28 22:18:03.302: E/AndroidRuntime(17631): at java.lang.reflect.Method.invokeNative(Native Method)
03-28 22:18:03.302: E/AndroidRuntime(17631): at java.lang.reflect.Method.invoke(Method.java:515)
03-28 22:18:03.302: E/AndroidRuntime(17631): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
03-28 22:18:03.302: E/AndroidRuntime(17631): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
03-28 22:18:03.302: E/AndroidRuntime(17631): at dalvik.system.NativeStart.main(Native Method)
Thank in advance.
This usually happens when the host activity for that fragment has performed onStop() and a commit() is called on a FragmentTransaction after that has happened(that is your when commit is called and your host activity is hidden).
Try using a local broadcast with a custom intent filter when push notification is received and use a broadcast receiver in your fragment for the update logic.
In which case if the fragment is visible when push notification happens it'll update otherwise let its onCreateView() handle the logic.
I'm trying to run the Spydroid app from . But run into a "Unfortunately Spydroid has stopped" as soon as it runs on my Nexus 4.
I used egit to grab a copy of the code into a new project in eclipse. At that point, it threw out a couple errors telling me to right click on the project and select Android Tools --> Fix Project Properties. I did as it said and then hit run, which uploads it to the Nexus 4, installs it and when it attempts to run is when I get the crash.
Am I doing something wrong in the checkout/setup process?
I posted a similar post to the project's google code page
Logcat:
03-28 02:59:20.028: D/AndroidRuntime(31294): Shutting down VM
03-28 02:59:20.028: W/dalvikvm(31294): threadid=1: thread exiting with uncaught exception (group=0x41920930)
03-28 02:59:20.028: E/AndroidRuntime(31294): FATAL EXCEPTION: main
03-28 02:59:20.028: E/AndroidRuntime(31294): java.lang.RuntimeException: Unable to instantiate application net.majorkernelpanic.spydroid.SpydroidApplication: java.lang.ClassNotFoundException: Didn't find class "net.majorkernelpanic.spydroid.SpydroidApplication" on path: /data/app/net.majorkernelpanic.spydroid-1.apk
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.LoadedApk.makeApplication(LoadedApk.java:504)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4364)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.ActivityThread.access$1300(ActivityThread.java:141)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1294)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.os.Handler.dispatchMessage(Handler.java:99)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.os.Looper.loop(Looper.java:137)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.ActivityThread.main(ActivityThread.java:5041)
03-28 02:59:20.028: E/AndroidRuntime(31294): at java.lang.reflect.Method.invokeNative(Native Method)
03-28 02:59:20.028: E/AndroidRuntime(31294): at java.lang.reflect.Method.invoke(Method.java:511)
03-28 02:59:20.028: E/AndroidRuntime(31294): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
03-28 02:59:20.028: E/AndroidRuntime(31294): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
03-28 02:59:20.028: E/AndroidRuntime(31294): at dalvik.system.NativeStart.main(Native Method)
03-28 02:59:20.028: E/AndroidRuntime(31294): Caused by: java.lang.ClassNotFoundException: Didn't find class "net.majorkernelpanic.spydroid.SpydroidApplication" on path: /data/app/net.majorkernelpanic.spydroid-1.apk
03-28 02:59:20.028: E/AndroidRuntime(31294): at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:65)
03-28 02:59:20.028: E/AndroidRuntime(31294): at java.lang.ClassLoader.loadClass(ClassLoader.java:501)
03-28 02:59:20.028: E/AndroidRuntime(31294): at java.lang.ClassLoader.loadClass(ClassLoader.java:461)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.Instrumentation.newApplication(Instrumentation.java:968)
03-28 02:59:20.028: E/AndroidRuntime(31294): at android.app.LoadedApk.makeApplication(LoadedApk.java:499)
03-28 02:59:20.028: E/AndroidRuntime(31294): ... 11 more
Possible error can be:
Check the package name carefully
Check order/export option in Build Path
I am trying to start an Activity from another activity with an ACTION_MAIN.
I am doing this because I want to give to other apps the possibility to start this secondary activity as well. So in my manifest I have two MAIN activities:
AndroidManifest.xml
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="main.package"
android:versionCode="34"
android:versionName="3.04"
android:installLocation="preferExternal"
>
....
<activity
android:name=".SplashActivity"
android:label="#string/app_name"
android:icon="#drawable/myicon"
>
<intent-filter >
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="main.package.secondary.SecondaryActivity"
android:label="#string/memorapp"
android:theme="#style/Theme.Sherlock.Light"
android:taskAffinity="main.package.secondary.SecondaryActivity"
>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
In my main activity I run the following code:
Intent intent = new Intent(Intent.ACTION_MAIN);
ComponentName cn = new ComponentName("main.package.secondary","main.package.secondary.SecondaryActivity");
intent.setComponent(cn);
startActivity(intent);
and here is the logcat:
03-28 16:35:41.987: E/AndroidRuntime(9921): FATAL EXCEPTION: main
03-28 16:35:41.987: E/AndroidRuntime(9921): android.content.ActivityNotFoundException: Unable to find explicit activity class {main.package.secondary/main.package.secondary.secondaryMainActivity}; have you declared this activity in your AndroidManifest.xml?
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1405)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.app.Instrumentation.execStartActivity(Instrumentation.java:1379)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.app.Activity.startActivityForResult(Activity.java:2827)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.support.v4.app.FragmentActivity.startActivityForResult(FragmentActivity.java:674)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.app.Activity.startActivity(Activity.java:2933)
03-28 16:35:41.987: E/AndroidRuntime(9921): at main.package.MainActivity.onMenufrag(MainActivity.java:206)
03-28 16:35:41.987: E/AndroidRuntime(9921): at main.package.MenuFragment.sendBodyTextToActivity(MenuFragment.java:92)
03-28 16:35:41.987: E/AndroidRuntime(9921): at main.package.MenuFragment.access$0(MenuFragment.java:90)
03-28 16:35:41.987: E/AndroidRuntime(9921): at main.package.MenuFragment$1.onClick(MenuFragment.java:66)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.view.View.performClick(View.java:2501)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.view.View$PerformClick.run(View.java:9107)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.os.Handler.handleCallback(Handler.java:587)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.os.Handler.dispatchMessage(Handler.java:92)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.os.Looper.loop(Looper.java:130)
03-28 16:35:41.987: E/AndroidRuntime(9921): at android.app.ActivityThread.main(ActivityThread.java:3835)
03-28 16:35:41.987: E/AndroidRuntime(9921): at java.lang.reflect.Method.invokeNative(Native Method)
03-28 16:35:41.987: E/AndroidRuntime(9921): at java.lang.reflect.Method.invoke(Method.java:507)
03-28 16:35:41.987: E/AndroidRuntime(9921): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:847)
03-28 16:35:41.987: E/AndroidRuntime(9921): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:605)
03-28 16:35:41.987: E/AndroidRuntime(9921): at dalvik.system.NativeStart.main(Native Method)
Could you tell me why my Activity is not found or what should I do so that my SecondaryActivity is started
Could you try this?
Intent intent = new Intent(Intent.ACTION_MAIN);
ComponentName cn = new ComponentName("main.package","main.package.secondary.SecondaryActivity");
intent.setComponent(cn);
startActivity(intent);
First paramater takes "Application package name"
Try setting the following intent-filters to your second activity:
<intent-filter>
<action android:name="main.package.secondary.SecondaryActivity" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
Put in manifest.xml:
<activity android:name="main.package.secondary.SecondaryActivity" android:label="#string/memorapp" android:theme="#style/Theme.Sherlock.Light" android:taskAffinity="main.package.secondary.SecondaryActivity"> </activity>
without intent-filter atributes.
private Drawable drawable;
drawable = this.getResources().getDrawable(R.drawable.icon);
When I run this on my htc desire it goes, but on emulator it crashes when I try to initialiser drawable. Why is this?
edit: here is my stacktrace
03-28 13:27:58.453: ERROR/ActivityThread(888): Failed to find provider info for com.google.settings
03-28 13:28:06.414: ERROR/AndroidRuntime(888): Uncaught handler: thread main exiting due to uncaught exception
03-28 13:28:06.486: ERROR/AndroidRuntime(888): java.lang.RuntimeException: Unable to start activity ComponentInfo{be.test.helloworld/be.test.helloworld.MyMapActivityII}: android.content.res.Resources$NotFoundException: Resource ID #0x7f020000
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2268)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2284)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.ActivityThread.access$1800(ActivityThread.java:112)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1692)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.os.Handler.dispatchMessage(Handler.java:99)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.os.Looper.loop(Looper.java:123)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.ActivityThread.main(ActivityThread.java:3948)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at java.lang.reflect.Method.invokeNative(Native Method)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at java.lang.reflect.Method.invoke(Method.java:521)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:782)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:540)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at dalvik.system.NativeStart.main(Native Method)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): Caused by: android.content.res.Resources$NotFoundException: Resource ID #0x7f020000
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.content.res.Resources.getValue(Resources.java:846)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.content.res.Resources.getDrawable(Resources.java:534)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at be.test.helloworld.MyMapActivityII.initOverlays(MyMapActivityII.java:44)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at be.test.helloworld.MyMapActivityII.onCreate(MyMapActivityII.java:38)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1123)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2231)
03-28 13:28:06.486: ERROR/AndroidRuntime(888): ... 11 more
Make sure you have an icon in all of the drawable folders (drawable-ldpi, drawable-mdpi and drawable-hdpi)
Getting the following in LogCat:
03-28 16:18:57.795: WARN/ResourceType(8351): No package identifier when getting name for resource number 0x00000001
03-28 16:18:57.865: WARN/ImageView(8351): Unable to find resource: 1
03-28 16:18:57.865: WARN/ImageView(8351): android.content.res.Resources$NotFoundException: Resource ID #0x1
03-28 16:18:57.865: WARN/ImageView(8351): at android.content.res.Resources.getValue(Resources.java:891)
03-28 16:18:57.865: WARN/ImageView(8351): at android.content.res.Resources.getDrawable(Resources.java:579)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.ImageView.resolveUri(ImageView.java:485)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.ImageView.setImageResource(ImageView.java:270)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.SimpleCursorAdapter.setViewImage(SimpleCursorAdapter.java:217)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.SimpleCursorAdapter.bindView(SimpleCursorAdapter.java:165)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.CursorAdapter.getView(CursorAdapter.java:186)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.AbsListView.obtainView(AbsListView.java:1274)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.ListView.measureHeightOfChildren(ListView.java:1147)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.ListView.onMeasure(ListView.java:1060)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.View.measure(View.java:7964)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3023)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:888)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.LinearLayout.measureHorizontal(LinearLayout.java:619)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.LinearLayout.onMeasure(LinearLayout.java:280)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.View.measure(View.java:7964)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3023)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.View.measure(View.java:7964)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.LinearLayout.measureVertical(LinearLayout.java:464)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.LinearLayout.onMeasure(LinearLayout.java:278)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.View.measure(View.java:7964)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3023)
03-28 16:18:57.865: WARN/ImageView(8351): at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.View.measure(View.java:7964)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.ViewRoot.performTraversals(ViewRoot.java:763)
03-28 16:18:57.865: WARN/ImageView(8351): at android.view.ViewRoot.handleMessage(ViewRoot.java:1633)
03-28 16:18:57.865: WARN/ImageView(8351): at android.os.Handler.dispatchMessage(Handler.java:99)
03-28 16:18:57.865: WARN/ImageView(8351): at android.os.Looper.loop(Looper.java:123)
03-28 16:18:57.865: WARN/ImageView(8351): at android.app.ActivityThread.main(ActivityThread.java:4363)
03-28 16:18:57.865: WARN/ImageView(8351): at java.lang.reflect.Method.invokeNative(Native Method)
03-28 16:18:57.865: WARN/ImageView(8351): at java.lang.reflect.Method.invoke(Method.java:521)
03-28 16:18:57.865: WARN/ImageView(8351): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
03-28 16:18:57.865: WARN/ImageView(8351): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-28 16:18:57.865: WARN/ImageView(8351): at dalvik.system.NativeStart.main(Native Method)
Actually, resource files exists (R.drawable.star_on at drawable-hdpi and drawable-ldpi, Eclipse has this value in autocomplete), here is the extract from R.java:
public static final class drawable {
public static final int star_off=0x7f020007;
public static final int star_on=0x7f020008;
Try cleaning and building the project.
Android is searching the image with id resource 0x00000001, which is not correct.
If that doesn't works try deleting the "gen" folder and building again.
Good luck :)
Strange, but the problem was with setViewValue function - I was changing ListView icon based on DB value and I didn't return true there (returned false) and hence I was getting this error.
Looks like a compilation error. Check your console for a red error message when it tries to build.
Does you have a resource that you have called 1.png 1.gif 1.mp4?
You cannot have resources that have a filename of a number.