"Show in folder" function in chrome packaged app - filesystems

I want implement a function in chrome app. my app received file from network, and i saved it in the local filesystem. how could i implement the function "show in folder". the same as browser to show download files. or implement the function "open file".

Related

Can I open .aprx file from ReactJS application to launch ArcGIS Pro software?

Can we directly open a desktop application on a button click event from React application? I need to open a locally installed software project file to launch in desktop mode. I have an .aprx file to launch ArcGIS Pro software which I am trying to invoke from front end.
Tried to code using anchor link, but encountered error saying "Not allowed to load local resource" !
Thanks,
Paul
Tried to invoke the .aprx file using full local path but failed.
Nope, that isn't possible due to various security restrictions. However, if the application handles custom URL schemes (e.g. some-app://a-resource), you can redirect to those URLs which would open a browser prompting the user for confirmation if they'd like to open the application. That's the approach that web apps like Word online use to make the "open in desktop app" work.

ionic 5 PDFTron Webviewer doesn't have access to file URLs because of browser security restrictions

I try to integrate the PDFTron API in an ionic 5 application in which I download the pdf from the server, store them on the phone and then open them with the API
currently when I put the files in the assets folder of my ionic project, the api opens it without problem
but when I download the file to the phone memory and try to open it with the API by passing the link of this file, I have the following error (on the image)
Is there a way to fix this or store the downloaded files in the assets folder?
for those who encounter this same problem, just convert the native url (Ex file: ///storage/emulated/0/USL/20.PDF) into a url that the webviewer accepts using this:
let safeURL = win .Ionic.WebView.convertFileSrc (your native url);
you can also follow this link: where was file location downloaded in Ionic
For security reasons, browsers normally don't allow JavaScript pages to load local files from the local environment. Your option for this is to either use local paths if possible to run or to create a local server that access and serve the file to the client side.

Problems testing Office Add-In with an already Existing Web API project

I have a Web API service that is tested and working well. In a separate project I have an Outlook Web Add-In. The UI is working just fine. Now, I would like to make calls to the Web Service I've created.
The Web API project launches IIS (using SSL)
I've copied (copy/paste) the Office Add-In folders to what would be the root folder ... (at least I think I have the web root folder)
After launching the Web Service from Visual Studio, I run OWA and side load my Add-in. The right Icon appears. When I click on one of the commands in the drop down, nothing happens. Chrome's debugger doesn't show any messages that would indicate that my Add-in has been called. No errors.

App not showing up in "Open with" menu in Drive UI

I'am writing an app using Google App Engine and I want to integrate it with google drive api. Specifically I want to implement the functionality that when you right click on a txt file in the drive UI, it lets me open the file using my app as described here.
I have gone through the oauth2 using decorators in python on the server side and I am able to e.g. read information from drive files from my app.
My app is also listed in Drive under settings > Managing Apps
But it still does not show up under the Open With menu.
I have also enabled the Drive Api in the developer console, and set a Open URL to a URL under my domain and Default file extension to txt
What am I missing?
Apparently I had not enabled the correct scopes in my server-side OAuth2 authorization.
Previously I had only the scope:
https://www.googleapis.com/auth/drive
However, when I enabled the following scopes
https://www.googleapis.com/auth/drive.install
https://www.googleapis.com/auth/drive.file
profile
It worked

Launch a Win Forms app from a metro app(using java script and html)

I want to launch a Win Form app from a metro style application.I tried Launcher.LaunchFileAsync(IStorageFile) | launchFileAsync(IStorageFile) API
but the documentation says as metro application runs in a sand-boxed environment, many file types that contain executable code, for example .exe, .msi, and .js files, are blocked from launching.
I also tried Launcher.LaunchUriAsync(Uri, LauncherOptions) | launchUriAsync(Uri, LauncherOptions) method wherein you need to pass a URI and options to launch the application.But,apps cannot use the file:/// protocol to access files on the local computer.
Is there a way i can create and launch a batch(.bat)file from my metro style application so that it will somehow execute the commands in it and launch the launching app .exe with some options?
Any help will be appreciated :)
Metro/WinRT/UWP app can't directly launch another application. It can do only one of the following:
Ask operating system to open specific file via some app registered in system for such file extensions. It is not about .exe files, but passing documents between applications. E.g. you can register your WinForms app in the OS to open .xyz files. Then you use the LaunchFileAsync API to open such file from your WinRT app. System will launch default application registered to open such files.
Ask operating system to react to a specific protocol via some app registered in system for such protocol. It is not about file:/// protocol, but about other protocol to enable app-to-app communication and delegating actions. E.g. you can register your WinForms app in the OS to react to the myapp-xyz: protocol. Then you can use the LaunchUriAsync API to ask OS to launch some app that can deal with such protocol. System will launch default application registered to support that protocol.

Resources