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 6957543
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T15:01:00+00:00 2026-05-27T15:01:00+00:00

We all know how we can use intent-filters in our AndroidManifest.xml to declare capabilities

  • 0

We all know how we can use intent-filters in our AndroidManifest.xml to declare capabilities of activities such as search, push, and so on. I currently use such an intent-filter to register a custom URL scheme in the following manner:

<activity android:name="NameOfActivity" >
    <intent-filter >
        <action android:name="android.intent.action.VIEW" />
        <category android:name="android.intent.category.DEFAULT" />
        <category android:name="android.intent.category.BROWABLE" />
        <data
            android:host=""
            android:scheme="customscheme" />
    </intent-filter>
</activity>

This all worked very well until I decided to transform all my activities into fragments, as I needed to display the user interface in a different manner on tables. Now, on devices that are declared as large or greater, instead of switching between activities I have one activity that removes and adds new fragments as requested. This choice was taken as the left-hand side of the screen allways displays the same content, so instead of adding this content ito all activities I instead change the fragments.

The problem here is that while the intent-filter launches the correct activity on the phone, this activity should never be launched on a tablet. Instead, I would like to handle this URL in the fragment. As of now, I see no way of fixing this. One thought was to add the intent-filter programmatically, but after some research i cannot figure out if this is possible or not. Another thought was to somehow add the intent-filter on the fragment, but this would not work as a fragment cannot launch without an activity hosting it.

In short:
On a phone, I need one activity to handle the intent-filter, but on a tablet I need another activity to handle the intent-filter.

Is there any way of accomplishing this?

  • 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-05-27T15:01:01+00:00Added an answer on May 27, 2026 at 3:01 pm

    After one month, I have yet to find a solution to this. As of know, the activity is launched on top of everything else. It breaks the whole flow, and is a quite bad workaround, but at least it works. Excluding the feature was a no-go, and thus this was the only solution. I would be really happy to see a better solution to this, but as of know it seems that it simply is not possible.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

As we all know,we can use such api as LockWorkStation() in user32.dll to lock
We all know you can't do the following because of ConcurrentModificationException : for (Object
We all know that you can overload a function according to the parameters: int
I am new to Xcode. I want to know how can I know all
I'm talking about the performance increase here. From all I know you can echo
We all know the trouble overflows can cause, and this is why strn* exist
We all know the effects that lots of thrown exceptions can have over the
As we all know tracking the position of a moving iOS device can be
As I'm sure you all know, Internet Explorer can handle simple gradients. Here is
Folks, we all know that IP blacklisting doesn't work - spammers can come in

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.