Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7945759
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 4, 20262026-06-04T00:58:09+00:00 2026-06-04T00:58:09+00:00

Hi i have to do connectivity between android app and browser. So while clicking

  • 0

Hi i have to do connectivity between android app and browser. So while clicking a button on browser it should redirect to android app. in android activity i have written

Uri data = getIntent().getData(); 
        if (data.equals(null)) { 
            System.out.println("Data is null");
        } else { 
            String scheme = data.getScheme();
            System.out.println(scheme);
            String host = data.getHost(); 
            int port = data.getPort(); 
            List<String> params = data.getPathSegments();
            String first = params.get(0); // "hello"
            System.out.println(first);

and in manifest i have already given

<intent-filter>
                <data android:scheme="Integration" />
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.BROWSABLE" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>

in html on button click i have given <FORM METHOD="LINK" ACTION="Integration://1">

it is throwing a indexoutofboundexception.
Please tell me where is the mistake

Updated
*I was unnecessarily using intent in an activity. By removing that n parameter in html5 my app is running successfully now.*

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-04T00:58:10+00:00Added an answer on June 4, 2026 at 12:58 am

    Quoting answer from: How to listen for a custom URI

    To register a protocol in your android app, add an extra block to the AndroidManifest.xml

    I modified the code a little, but thought I’d quote the source too

    <manifest>
     <application>
       <activity android:name=".activityToCall">
               <intent-filter>
                    <action android:name="android.intent.action.VIEW" />
                    <category android:name="android.intent.category.DEFAULT" />
                    <category android:name="android.intent.category.BROWSABLE" />
                    <data android:scheme="scheme" android:host="path"/>
                </intent-filter>
       </activity>
     </application>
    </manifest>
    

    Then when a url matching your schema is opened your app will be called to handle it I assume.
    Taking into consideration that scheme and pathcorrespond to this:

    scheme://host/path
    

    After that, in the activity you’ve set in the manifest to handle this stuff:

    Uri data = getIntent().getData(); 
    if (!data.equals(null)){ 
        String scheme = data.getScheme(); 
        //Or whatever you needed
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hi i have to do connectivity between browser and android app. I referred the
So I have all these classes put together for all the connectivity between Predators
I have developed servlet on apache tomcat which is having mysql connectivity. and android
I have a lot of trouble with the internet connectivity in the program I
OK I have two web projects WebProject1 & WebProject2. Both require database connectivity so
Have you ever tried learning a language while on a project? I have, and
I have transactional replication running between two servers over a dedicated VPN connection. The
I have following code for testing the server connectivity. I have a device that
I have this piece of code (from the Nokia PC connectivity 3.2 example code,
I currently have a connection class that handles all of my database connectivity. What

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.