Hey,
I have a solution for your problem.All you have to do is when need to
install your app-widget-supported app don't do 'adb install
filename.apk'..this will install your app in /data/app folder.Thus
wont have permission to access app-widgets. Instead use 'adb push
filename.apk /system/app ' .This might solve your problem.If the
problem still persists..don't worry...Remove '/data/system/
packages.xml' file and restart the device.don't forget to take back-up
of packages.xml if something goes wrong.Let me know if everything goes
fine for you.


regards,
Ravi Pandit - The PPite
PathPartner Tech,Bangaluru.

On May 26, 1:41 pm, Peter <[email protected]> wrote:
> Hey,
>
> Deren, you did it correctly. But there is something missing. The
> android.permission.BIND_APPWIDGET permission is a system permission.
> You can only get that permission if your package is installed as a
> system package (installed in /system/app in stead of /data/app) or
> sign you app with a certificate that's the same as your android image.
> So basicly this means you can only use this permission if you are also
> the creator of the android image on your platform/phone.
>
> Regards,
>
> Peter
>
> On Apr 20, 12:25 pm, AndroidNewbie <[email protected]> wrote:
>
> > I am facing the exact same issue . Can someone help please ? Deren ,
> > were you able to get the help from someone ?
>
> > On Feb 20, 5:15 pm, Deren <[email protected]> wrote:
>
> > > I've successfully built a small sample app where the user can add a
> > > appwidget, using the AppWidgetPicker, using the action
> > > AppWidgetManager.ACTION_APPWIDGET_PICK. When I do this, the
> > > AppWidgetPicker takes care of binding my appwidget-id to a provider.
> > > However, now I'd like to load some widgets without using the
> > > AppWidgetPicker (for instance, maybe I want to restore the added
> > > appwidgets when I restart the application or something). I've tried
> > > the following code
>
> > > ComponentName widget = new ComponentName("com.android.alarmclock",
> > > "com.android.alarmclock.AnalogAppWidgetProvider");
>
> > > int appWidgetId = mAppWidgetHost.allocateAppWidgetId();
> > > mAppWidgetManager.bindAppWidgetId(appWidgetId, widget);
>
> > > but it fails with a SecurityException, even though I've added
>
> > > <uses-permission android:name="android.permission.BIND_APPWIDGET"/>
>
> > > to my manifest file. Is this the way to do it? (using
> > > AppWidgetManager.bindAppWidgetId). Im using the emulator, and android
> > > 2.1.
>
> > --
> > You received this message because you are subscribed to the Google
> > Groups "Android Developers" group.
> > To post to this group, send email to [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]
> > For more options, visit this group 
> > athttp://groups.google.com/group/android-developers?hl=en
>
>

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to