Hi,

I have an example of code bellow:

        private class BootReceiver extends BroadcastReceiver {
                @Override
                public void onReceive(Context context, Intent intent) {
                        if
(intent.getAction().equals(Intent.ACTION_BOOT_COMPLETED)) {
                                Toast.makeText(context,
                                        "Click the right corner of the
status bar to enable or disable\nHome/Menu/Back touch features",
                                        Toast.LENGTH_LONG).show();
                                return;
                        }
                }
        }

Inside your class you do this:

                mIntentFilter = new
IntentFilter(Intent.ACTION_BOOT_COMPLETED);
                mBootReceiver = new BootReceiver();
                mContext.registerReceiver(mBootReceiver, mIntentFilter);

This is is a piece of code from file TouchFeature.java
You can find this file in the source of android-x86.

Regards,

Rogerio

2010/1/18 Manoj <[email protected]>

> Hi ,
> Can anybody tell about the Broadcast Receiver in android to make make
> my service to run when the the phone just finishes the booting.
>
> --
> 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]<android-developers%[email protected]>
> For more options, visit this group at
> http://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