Android Question copy to clipboard?

Discussion in 'Android Questions' started by ilan, Dec 11, 2016.

  1. ilan

    ilan Expert Licensed User

  2. Ohanian

    Ohanian Active Member Licensed User

    ilan likes this.
  3. ilan

    ilan Expert Licensed User

    Awesome. But dont i need to add something to the manifest?
     
  4. Ohanian

    Ohanian Active Member Licensed User

    as far as i remember no.
    i don't have access to my code, i'll check it tomorrow if you face any problem.
     
    ilan likes this.
  5. ilan

    ilan Expert Licensed User

    just tried it, it works but as long the service is running. and i would like to avoid running a forground service
    so i need to add an intent filter to the manifest that will start this service when someone copy something to the clipboard

    something like this

    Code:
    AddReceiverText(clipboard,
    <
    intent-filter>
        <action android:name=
    "android.intent.action.onPrimaryClipChanged" />
    </
    intent-filter>)
    i just dont know the right intent action :(:(

    (ps clipboard is the service)
     
  6. ilan

    ilan Expert Licensed User

    if there is no intent filter for that i will use a sticky service.

    thanx a lot @Ohanian :)
     
  7. MitchBu

    MitchBu Active Member Licensed User

  8. ilan

    ilan Expert Licensed User

Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice