For item 2 I believe this scan be done using <LaunchUri Uri="file://guff.pdf" /> which should then open as long as the phone has a built in PDF viewer.
Hey, you have to use Uno to be able to do that now (you can enumerate Uno.IO.Bundle.AllFiles to find the file and get the path). I will make a ticket so we expose the path through the Bundle API in JS.
This was not as easy as I thought since the bundle files are actually bundled into a JAR file on Android and into a dll on windows. I made a sample where temporary store the file in the application folder and then retrieve the file path.
When testing the below code I console.log the uri variable and get the following ouput: I/BundlePathTest(10506): file:///data/data/com.BundlePathTest/files/generic.pdf which looks correct. However when I try to open the file via LaunchUri I get the unhandled exception: There is an invalid character sequence in uriString.
If I remove the third slash (file:///data... to file://data) the unhandled exception is no longer thrown and the device tries to open the file but cannot locate it.
MainView.ux
<App Theme="Basic">
<JavaScript>
var bp = require("BundlePath");
var file = bp.getPath("generic.pdf");
var uri = "file://"+file;
console.log(uri);
module.exports = {
file: uri
}
</JavaScript>
<DockPanel>
<Button Text="Open PDF">
<Clicked>
<LaunchUri Uri="{file}" />
</Clicked>
</Button>
</DockPanel>
</App>