Thanks Mark. Now that I know what to be searching for, I've found
several similar topics mostly on stackoverflow.

Most topics have a response by Hackbod, stating not to do it that way,
but I'm struggling a little to understand what it is he's suggesting
instead.

http://stackoverflow.com/questions/3469908/make-a-link-in-the-android-browser-start-up-my-app

So far I've got an example link from a WebView to open up the 'choose
application' selector, which does at least contain my app - but I want
it to open my app automatically.

I don't get this bit:

"The best way to use this, if you want to ensure it launches only your
app, is with your own scoped action and using Intent.setPackage() to
say the Intent will only match your app package."

and also...

"Finally, you may want to set the package of the intent to your app
with this: 
http://developer.android.com/reference/android/content/Intent.html#setPackage(java.lang.String)

This is a newer feature in the platform, which allows you to direct
link intents to only your app so that other applications can not
intercept and handle them."

Where exactly is he suggesting that I use this? My link is going to
come from an external browser over which I have little control.

On Nov 7, 1:18 pm, Mark Murphy <mmur...@commonsware.com> wrote:
> On Mon, Nov 7, 2011 at 8:14 AM, Neilz <neilhorn...@gmail.com> wrote:
> > Hi all. From my app I want to send the user to a web page to complete
> > some action, and then return to the app with some kind of code,
> > depending upon the success or failure of their action.
>
> > How can I achieve this? Will I have to use a WebView within the app,
> > or is there a way I can use the stock browser also?
>
> In theory, if you have the browser redirect to some URL that is
> handled by your app (ACTION_VIEW, CATEGORY_BROWSABLE, and an
> appropriate <data> element), you could accomplish this with your
> "code" baked into the URL (e.g., /postaction/success and
> /postaction/failure). I haven't tried a redirect as the trigger
> mechanism, though.
>
> --
> Mark Murphy (a Commons 
> Guy)http://commonsware.com|http://github.com/commonsguyhttp://commonsware.com/blog|http://twitter.com/commonsguy
>
> Android Training...At Your Office:http://commonsware.com/training

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to