it's not a Studio thing, it's an Android thing.  You can not start a
service until the user explicitly starts an activity first, this is to
prevent a malicious app from covertly starting a service that does nasty
things without the user ever knowing about it!  You likely want to give the
user some control over the service anyhow, at least the ability to turn it
on and off.  This is nicely accomplished by a configuration activity which
will satisfy the activity requirement.

On Oct 18, 2016 10:39 AM, "Petar Petrovic" <pepe7...@gmail.com> wrote:

> Hello everyone. I'm making service app in Android Studio. I tried with
> onBOOT receiver, and it is working when I add Activity, but I don't need
> Activity. Can someone help me? Is it possible from android studio to
> achieve that?
> Problems are android configuration for applications, where default
> Activity is started, and Manifest file where you can specify Activity and
> launching.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Android Developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to android-developers+unsubscr...@googlegroups.com.
> To post to this group, send email to android-developers@googlegroups.com.
> Visit this group at https://groups.google.com/group/android-developers.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/android-developers/4631e020-e187-4357-b504-
> ba9be9122b9a%40googlegroups.com
> <https://groups.google.com/d/msgid/android-developers/4631e020-e187-4357-b504-ba9be9122b9a%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to android-developers+unsubscr...@googlegroups.com.
To post to this group, send email to android-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/android-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-developers/CABfabRg%2Bdjfm3LQyiWV6zZTky7w0W8nNvV2k0MY-2a1c4C8ChQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to