1. Download our Official Android App: Forums for Android!

[Tasker] how to kill a task by another task?

Discussion in 'Android Apps & Games' started by ldm1417, Oct 11, 2018 at 5:13 PM.

  1. ldm1417

    ldm1417 Member
    Thread Starter
    Rank:
     #644
    Points:
    16
    Posts:
    57
    Joined:
    Aug 7, 2018

    Aug 7, 2018
    57
    8
    16
    Hi All,

    Is there a way to kill a Tasker's task, which was started on the Device Boot and runs in indefenite loop (the loop is implemented inside of the task) ?

    Thank you!
     

    Advertisement

  2. Thom

    Thom  
    VIP Member
    Rank:
     #21
    Points:
    1,318
    Posts:
    12,002
    Joined:
    Feb 16, 2011

    Feb 16, 2011
    12,002
    4,970
    1,318
    Male
    Software Developer
    Keene, NH USA
    Use a global variable like %StopMe

    In the task that is looping have it check the global variable for a predefine value each time it loops. If it matches terminate the loop.

    The other task then just sets the predefined value when it wants the loping task to end.

    If the tasks are separately compiled use an Intent to send the predefined value from one to the other.

    … Thom
     
    #2 Thom, Oct 11, 2018 at 7:18 PM
    Last edited: Oct 13, 2018 at 11:13 AM
    ldm1417 likes this.

Share This Page

Loading...