Android Question Choice Foreground or Stick Service programmable ?

Discussion in 'Android Questions' started by kohle, Jun 13, 2015.

  1. kohle

    kohle Active Member Licensed User

    Is there a way that I can decide
    if the service will run in foreground or as sticky service ?

    My idea is put :
    in the Service attributes

    and do something like this in the SERVICE_CREATE :

    if flg_run_foreground = 1 then
    end if

    Is this possible ?
  2. Erel

    Erel Administrator Staff Member Licensed User

    You cannot change the "sticky" state at runtime.