this post was submitted on 23 Jul 2023
7 points (100.0% liked)

Ask Android

2073 readers
4 users here now

A place to ask your questions and seek help related to your Android device and the Android ecosystem.

Whether you're looking for app recommendations, phone buying advice, or want to explore rooting and tutorials, this is the place for you!

Rules
  1. Be descriptive: Help us help you by providing as many details as you can.
  2. Be patient: You're getting free help from Internet strangers, so you may have to wait for an answer.
  3. Be helpful: If someone asks you for more information, tell us what you can. If someone asks you for a screenshot, please provide one!
  4. Be nice: Treat others with respect, even if you don't agree with their advice. Accordingly, you should expect others to be nice to you as well. Report intentionally rude answers.
  5. No piracy: Sharing or discussing pirated content is strictly prohibited. Do not ask others for a paid app or about how to acquire one.
  6. No affiliate/marketing links: Posting affiliate links is not allowed.
  7. No URL shorteners: These can hide the true location of the page and lead people to malicious places.
  8. No lockscreen bypasses: Please do not comment, link, or assist with bypassing lock screens or factory reset protection.
  9. No cross-posting: Please take the time to make a proper post instead of cross-posting.
Other Communities

founded 1 year ago
MODERATORS
 

I'm trying to create a shortcut to internet connectivity panel using Tasker/Macrodroid.

So far I've learned i need to call ACTION_INTERNET_CONNECTIVITY but I don't know how.

I'm a noob and don't know anything about Android development. Can someone please help?

Update: solved by using this intent: android.settings.panel.action.INTERNET_CONNECTIVITY

top 4 comments
sorted by: hot top controversial new old
[–] [email protected] 5 points 1 year ago (1 children)

Sure, I can guide you through the process. Since you mentioned both Tasker and MacroDroid, I'll outline the process for each.

  1. Tasker:

    • In Tasker, you would first need to create a new task. You can do this by going to the "Tasks" tab and clicking the "+" button.

    • Then, give your task a name. Something like "Open Internet Connectivity Panel" might be appropriate.

    • In your new task, you'll need to add an action. To do this, click the "+" button inside your task.

    • You want to use the "Send Intent" action. This can be found under the "System" category.

    • In the "Action" field of the "Send Intent" action, you would put "android.settings.WIRELESS_SETTINGS". This is the intent that opens the wireless & networks settings page, which includes the internet connectivity settings.

    • You can leave the other fields blank, as they are not needed for this intent.

    • Finally, you can link this task to a shortcut on your home screen by long pressing on an empty space on your home screen, selecting "Widgets", and then finding the "Task Shortcut" widget from Tasker.

  2. MacroDroid:

    • In MacroDroid, you would start by creating a new macro. This can be done from the main screen by clicking the "+" button.

    • For the trigger, you can select "Shortcut Launched", and then give your shortcut a name.

    • For the action, you want to use the "Launch Activity" action. This can be found under the "Applications" category.

    • In the "Launch Activity" action, you need to find the settings app, and then find the activity that corresponds to the internet connectivity settings. This might be something like "com.android.settings.Settings$WirelessSettingsActivity", but it can vary between devices.

    • Once you have set up the action, you can save your macro. It will automatically create a shortcut on your home screen that triggers the macro when clicked.

I hope this helps! If you have any further questions, feel free to ask.

[–] [email protected] 4 points 1 year ago

Thanks GPT4! The exact intent I needed was this: android.settings.panel.action.INTERNET_CONNECTIVITY

[–] WhoRoger 3 points 1 year ago (1 children)

You can use apps like Activity Manager or Activity Launcher, both on F-Droid. Some Launchers have the ability as well, Nova can/could do it. But not all activities can be launched in user space independently. Apps like these usually show you which can and can't.

[–] [email protected] 1 points 1 year ago

Already tried that and similar apps, but this activity is not listed.