Is it possible to open a file from a shared folder outside the browser

3.6k views Asked by At

We have a file handling ASP.Net web control used in intranet web applications, that currently uses ActiveX to handle file check-outs, and check-ins. Works fine, in IE&Win. But now we are trying to get rid of ActiveX & IE only behavior...

If a file is checked out, it is copied to file share, with access right limited to the checking-out user. Using a hidden iframe, and setting the src of the iframe to something like "file:////file_share/dictionary/users_stuff/someDoc.doc", an open/download dialog is shown, so the user can open and edit the shared file in Word, Excel, etc directly from the file share.

Works fine for file types browsers can't handle themselves.

But for file types like txt, images, html the browser simply loads the file to the iframe, or opens the file, if the user is given a link. And the user can't edit the file without manually launching the appropriate application and copying the url. Showing the users a "Copy this url to your preferred application, and try to edit it" would not be really user friendly...

My question is: is it possible to get the browser (without ActiveX, IE...) to pass the link to the OS, or show a "What do you want to do with this file" dialog of some sort?

If not, what and how could be achieved?

1

There are 1 answers

0
JFish222 On BEST ANSWER

The closest I could come up with is this thread: https://stackoverflow.com/a/1394725/1195927

@Red says no (and the original poster agrees) BUT @Daan seems to have a solution.
I have not tested, so YMMV.

If a javascript/html solution is not found, I may have an ugly hack for you . . .
See my post here: Launching a Downloadable Link