You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@flex.apache.org by After24 <vi...@after24.net> on 2020/05/15 15:35:30 UTC

Launching an AIR application (captive runtime) from an http link

Hello,

I'm searching for a way to open an AIR application from an http link. I
cannot find any information on this topic. Does anyone know if it is
possible (especially when the application is built with the captive runtime
option) ?

Thanks.

Vincent.



--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Launching an AIR application (captive runtime) from an http link

Posted by Alex Harui <ah...@adobe.com.INVALID>.
I'm pretty sure Zoom and other video chat apps are launching and installing from links.  Here's one SO post on the subject: https://stackoverflow.com/questions/14415012/how-to-launch-an-application-from-a-link-in-a-webpage-on-mac


On 5/18/20, 3:07 AM, "After24" <vi...@after24.net> wrote:

    Hi Alex,
    
    No, I don't know how to launch other programs from an http link either.
    But since the original Adobe method imply to load a .swf file in order to
    launch an AIR application, this will no longer be available from January 21.
    
    Never mind, this is not an essential feature for us so I will not spend more
    time on that.
    
    Thank you for your time (and congrats for the 0.9.7 Royal release !)
    
    Vincent
    
    
    
    --
    Sent from: https://nam04.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-flex-users.2333346.n4.nabble.com%2F&amp;data=02%7C01%7Caharui%40adobe.com%7C258c9899673d4441534a08d7fb133a64%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C1%7C637253932319960316&amp;sdata=EN%2BqSzigP%2BzrdbEHl%2FZSkN0rUvSvU5BXs%2FoGdVCad30%3D&amp;reserved=0
    


Re: Launching an AIR application (captive runtime) from an http link

Posted by After24 <vi...@after24.net>.
Hi Javier,

Thank you. This is very interesting. 
I Will try with the Navigator.registerProtocolHandler approach.

Have a nice day.

Vincent.





--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Launching an AIR application (captive runtime) from an http link

Posted by Javier Guerrero García <ja...@gmail.com>.
Hi Vincent:

All you have to do is make up an interesting name for the protocol part of
an URI scheme (for instance, "myapp://" or "batchfile://" or
"whatever://"), and just tell your operating system/browser how to open
URLS with that scheme (same as "you" did for "http://" schemes, "ftp://"
schemes, "mailto:" schemes, and so on).

For instance in a windows machine:

https://blog.xojo.com/2016/08/16/custom-uri-schemes-on-windows/
(ignore the Visual Basic gibberish, just take the concept)

Just enter the appropriate key under HKEY_CLASSES_ROOT and you're done.

For instance, I registered on my machine the "phantom://" protocol, to open
a phantomJS browser (in fact, phantomJS is called by a batch file with a
parameter as you see below). This are the contents of the .reg file to
register:

[HKEY_CLASSES_ROOT\phantom]
> @="URL:phantom Protocol"
> "URL Protocol"=""
> [HKEY_CLASSES_ROOT\phantom\shell]
> [HKEY_CLASSES_ROOT\phantom\shell\open]
> [HKEY_CLASSES_ROOT\phantom\shell\open\command]
> @="\"E:\\Documents\\misc\\phantomJS\\phantom.bat\" \"%1\""


That way, if I link to "phantom://thisfile.txt" on the intranet (for
instance), my browser (after some complaining the very first time) will
actually launch "E:\Documents\misc\phantomJS\phantom.bat thisfile.txt" on
this machine.

You can use any protocol name you want, as far as that name is not already
registered in HKEY_CLASSES_ROOT by any other app. Another handy one is
"pdfprint://", that could launch AcroReader.exe with the /p option for
direct printing a PDF form, etc...

Hope it helps :-) And yes, *don't forget to restart your browser after any
protocol registrations*, otherwise it would just ignore them and you will
just get crazy figuring it out.

P.S. Not tried, but apparently under certain circumstances you can also do
something similar directly from a webpage instead of fiddling with the
operating system:
https://developer.mozilla.org/en-US/docs/Web/API/Navigator/registerProtocolHandler


On Mon, May 18, 2020 at 12:07 PM After24 <vi...@after24.net> wrote:

> Hi Alex,
>
> No, I don't know how to launch other programs from an http link either.
> But since the original Adobe method imply to load a .swf file in order to
> launch an AIR application, this will no longer be available from January
> 21.
>
> Never mind, this is not an essential feature for us so I will not spend
> more
> time on that.
>
> Thank you for your time (and congrats for the 0.9.7 Royal release !)
>
> Vincent
>
>
>
> --
> Sent from: http://apache-flex-users.2333346.n4.nabble.com/
>

Re: Launching an AIR application (captive runtime) from an http link

Posted by After24 <vi...@after24.net>.
Hi Alex,

No, I don't know how to launch other programs from an http link either.
But since the original Adobe method imply to load a .swf file in order to
launch an AIR application, this will no longer be available from January 21.

Never mind, this is not an essential feature for us so I will not spend more
time on that.

Thank you for your time (and congrats for the 0.9.7 Royal release !)

Vincent



--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Launching an AIR application (captive runtime) from an http link

Posted by Alex Harui <ah...@adobe.com.INVALID>.

On 5/17/20, 11:44 AM, "After24" <vi...@after24.net> wrote:

    Hi Alex,
    
    Thanks you for your answer.
    
    You mean launching other apps from the AIR application using NativeProcess ?
    
No, I meant, can you launch other programs or batch/script files from an http link?  I don't know this area very well, so I'm trying to understand if you can do this for other scenarios except AIR or are looking for AIR to allow something you can't do otherwise.

-Alex

    Vincent.
    
    
    
    
    
    
    
    --
    Sent from: https://nam04.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-flex-users.2333346.n4.nabble.com%2F&amp;data=02%7C01%7Caharui%40adobe.com%7C90ccd8c7f4624b6bf9cf08d7fa925974%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C1%7C637253378793778061&amp;sdata=6Ctq29VF7XHh5H0wwrk%2BIsZdyNt%2BYMwxQAHbiH%2FPB5A%3D&amp;reserved=0
    


Re: Launching an AIR application (captive runtime) from an http link

Posted by After24 <vi...@after24.net>.
Hi Alex,

Thanks you for your answer.

You mean launching other apps from the AIR application using NativeProcess ?

Vincent.







--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Launching an AIR application (captive runtime) from an http link

Posted by Alex Harui <ah...@adobe.com.INVALID>.
Can you launch other apps, batch files, etc?  Is the bundle already installed or are you trying to download and install it?

-Alex

On 5/16/20, 6:58 AM, "After24" <vi...@after24.net> wrote:

    Hello Ramazan,
    
    Thank you for your answer.
    
    Unfortunately this method is not viable because I need to package the
    application as a captive runtime bundle and
    <allowBrowserInvocation>true</allowBrowserInvocation> is not allowed in that
    case (error 116: Browser invocation is not supported for this target).
    
    Vincent. 
    
    
    
    --
    Sent from: https://nam04.safelinks.protection.outlook.com/?url=http%3A%2F%2Fapache-flex-users.2333346.n4.nabble.com%2F&amp;data=02%7C01%7Caharui%40adobe.com%7C95e24d365555435733a508d7f9a13646%7Cfa7b1b5a7b34438794aed2c178decee1%7C0%7C1%7C637252343113634826&amp;sdata=%2Bebn3j%2F53us4ha9FwQiWkMBj8P7XucOpC1X26cvIQKI%3D&amp;reserved=0
    


Re: Launching an AIR application (captive runtime) from an http link

Posted by After24 <vi...@after24.net>.
Hello Ramazan,

Thank you for your answer.

Unfortunately this method is not viable because I need to package the
application as a captive runtime bundle and
<allowBrowserInvocation>true</allowBrowserInvocation> is not allowed in that
case (error 116: Browser invocation is not supported for this target).

Vincent. 



--
Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Launching an AIR application (captive runtime) from an http link

Posted by Ramazan Ergüder Bekrek <e....@yandex.com>.
There is one link which is dead but I found it with web archive : https://web.archive.org/web/20190215130044/http://archive.davidtucker.net/2008/01/11/air-tip-6-launching-an-application-from-the-browser/

15.05.2020, 22:21, "Ramazan Ergüder Bekrek" <e....@yandex.com>:
> Greetings dear Flexer
>
> I hope this will help you : https://stackoverflow.com/questions/9228761/how-to-launch-an-adobe-air-application-from-browser
>
> 15.05.2020, 17:35, "After24" <vi...@after24.net>:
>>  Hello,
>>
>>  I'm searching for a way to open an AIR application from an http link. I
>>  cannot find any information on this topic. Does anyone know if it is
>>  possible (especially when the application is built with the captive runtime
>>  option) ?
>>
>>  Thanks.
>>
>>  Vincent.
>>
>>  --
>>  Sent from: http://apache-flex-users.2333346.n4.nabble.com/

Re: Launching an AIR application (captive runtime) from an http link

Posted by Ramazan Ergüder Bekrek <e....@yandex.com>.
Greetings dear Flexer

I hope this will help you : https://stackoverflow.com/questions/9228761/how-to-launch-an-adobe-air-application-from-browser


15.05.2020, 17:35, "After24" <vi...@after24.net>:
> Hello,
>
> I'm searching for a way to open an AIR application from an http link. I
> cannot find any information on this topic. Does anyone know if it is
> possible (especially when the application is built with the captive runtime
> option) ?
>
> Thanks.
>
> Vincent.
>
> --
> Sent from: http://apache-flex-users.2333346.n4.nabble.com/