Guest User

Untitled

a guest
Jan 19th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. <application
  2. ...
  3. ...
  4. <service
  5. android:name="UploadService"
  6. android:icon="@drawable/icon"
  7. android:label="@string/app_name"
  8. android:process=":my_process" >
  9. </service>
  10. </application>
  11.  
  12. Log.e("UPLOAD_SERVICE","About to start service"); //This log always prints
  13. Intent i = new Intent(this,UploadService.class);
  14. startService(i);
  15.  
  16. public class UploadService extends IntentService {
  17.  
  18. public UploadService(String name) {
  19. super("UploadService");
  20. }
  21. public UploadService()
  22. {
  23. super("UploadService");
  24. }
  25.  
  26. @Override
  27. protected void onHandleIntent(Intent intent) {
  28.  
  29. Log.e("UPLOAD_SERVICE","The service has started"); //Never reached
  30. }
Add Comment
Please, Sign In to add comment