How do I make mit app inventor open url in chrome browser?

I tried this code but give me
error 601 no corresponding activity was found

From the Activity Starter doc:

  • Opening a browser to a specified web page. Assuming the page you want to go to is “www.facebook.com” (feel free to substitute your own choice), set the properties to:
    • Action: android.intent.action.VIEW
    • DataUri: http://www.facebook.com

Check case sensitivity.
https://code.appinventor.mit.edu/reference/components/connectivity.html#ActivityStarter

it gives me the same error

ResolveActivity()

Returns the name of the activity that corresponds to this ActivityStarter, or an empty string if no corresponding activity can be found.

Why do you call Start Activity before ResolveActivity?

It's Ready, Aim, Fire, not
Fire, Ready, Aim.

can you make an example

Try the fifth link in

The example in the doc leaves off two of the four parameters you gave.
What happens if you just supply the two doc parameters?

it does not work

From the FAQ, this app should help identify the activity starter setup:

This should be all you need if Chrome is your default browser

image

else it should open whatever is your default browser

You have capitalization issues with the Action block. action, not Action.

How do i make url of a particular site open in browsers? I tried these blocks but it doesn't work

You want
If url is google.com then it will run in chrome custom tab.
If url is Facebook.cok then it will open device browser?

Is it?

DataUri block is missing.

I want it to open in any browser the user has as their default browser... What will the data uri contain? The website i want to open?

Data uri is should be your target url.

But target url have different IDs in the url in each new pages, for example website.com/16353 or website.com/25374 will either open if i set the data uri to website.com ?

This block arrangements didn't work

This works well in the native webviewer

image

If using customwebview do you needs to set SupportMultipleWindows=true ?

1 Like

Do you have a browser installed on your phone?

1 Like