I dont't stopped in the debugger once you're hit OnCreate().but don't into OnStart().in the OnStart method add @Override,Program error,
<service android:enabled="true" android:name=".IntentServiceTest"> <intent-filter> <action android:name="IntentServiceTest"/> </intent-filter> </service> 2010/8/2 Kostya Vasilyev <kmans...@gmail.com> > Do you give it enough time? I mean, let it run, don't leave it stopped in > the debugger once you've hit onCreate(). > > It's not supposed to be called from super.onCreate(). > > Also check your declarations: > > public class BlahService extends Service { > > @Override > public void onCreate() { > // blah blah > } > > @Override > public void onStart(Intent intent, int startId) { > // blah blah > } > > @Override > public int onStartCommand(Intent intent, int flags, int startId) { > // blah blah > } > > @Override > public void onDestroy() { > } > > @Override > public IBinder onBind(Intent arg0) { > return null; > } > > } > > 02.08.2010 15:51, 汪健飞 пишет: > > In my program into OnCreate method after Activity startService > method,dont't run onStart method after OnCreate.I use android 1.5.I don't > know why? > > > > > 2010/8/2 Kostya Vasilyev <kmans...@gmail.com> > >> The intent is passed to the service's onStart / onStartCommand (Android >> 1.x / 2.x). >> >> onCreate is only called for service creation (once, at least until the >> process is killed), while onStart / onStartCommand are called every time you >> call startService, and are passed the intent you used with startService. >> >> -- Kostya >> >> 02.08.2010 13:56, 汪健飞 пишет: >> >>> In the Activity I write >>> >>> Intent i=new Intent("IntentServiceTest"); >>> Bundle bundle = new Bundle(); >>> bundle.putString("abc", "def"); >>> i.putExtra("wer", bundle); >>> IntentTest.this.startService(i); >>> Start Service into Service OnCreate method,but I don't know how to do get >>> this Intent in this method.Thanks! >>> >>> >>> -- >>> Cary >>> -- >>> You received this message because you are subscribed to the Google >>> Groups "Android Developers" group. >>> To post to this group, send email to android-developers@googlegroups.com >>> To unsubscribe from this group, send email to >>> android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com> >>> For more options, visit this group at >>> http://groups.google.com/group/android-developers?hl=en >>> >> >> >> -- >> Kostya Vasilev -- WiFi Manager + pretty widget -- >> http://kmansoft.wordpress.com >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Android Developers" group. >> To post to this group, send email to android-developers@googlegroups.com >> To unsubscribe from this group, send email to >> android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com> >> For more options, visit this group at >> http://groups.google.com/group/android-developers?hl=en >> > > > > -- > Cary > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to android-developers@googlegroups.com > To unsubscribe from this group, send email to > android-developers+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > > > > -- > Kostya Vasilev -- WiFi Manager + pretty widget -- > http://kmansoft.wordpress.com > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to android-developers@googlegroups.com > To unsubscribe from this group, send email to > android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com> > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > -- Cary -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en