• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Default app detect

Aniruddha060

Member
Aug 12, 2017
81
17
24
I want to launch the default browser or the default media player depending on the user's input. Is there a way tasker can detect which app is currently set to default for a particular task.

I have a scene with texts browser and music. When I select browser, I want it to launch the default app regardless of when it was changed and similarly for music.
 
I do not know how to do that. I think default is establish individually for an app.

Why not ask the user what browser to use and what music player to use and then you save those values and use them each time (until the user decides to chance them)?

… Thom

Thanks for the suggestion. But I still don't know how I'd set that in a variable and launch that app. Do you have a tutorial or could you point me to a good resource?
 
Upvote 0
Is your intent to have this capability run under Tasker or do you intend to crate a Kid and run the capability when Tasker is not available.?

You can set the app name in a global variable. If operating under Tasker it will be available even after you reload Tasker. If operating from a Kid it will be available even after you reload the Kid.

The variable under Tasker will not be accessible from the Kid. The variable under the Kid will not be accessible from Tasker.

This task illustrates it …

Dev5
A1: If [ %AAAAAA !Set ]
A2: Variable Set [ Name:%AAAAAA To:First - App Name Recurse Variables:Off Do Maths:Off Append:Off ]
A3: Else
A4: Variable Set [ Name:%AAAAAA To:Other - App Name Recurse Variables:Off Do Maths:Off Append:Off ]
A5: End If
A6: Flash [ Text:%AAAAAA Long:On ]

Run it once and it will show First
Run it again and it will show Other
Reload and run it and it will show Other

… Thom
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones