I am trying to use the Samsung Multiwindow-SDK function within my application to open a PDF in Polaris office.
I have the following code:
if (file.exists()) {
try{
Uri path2 = Uri.fromFile(file);
Intent i = new Intent(Intent.ACTION_VIEW);
i.setDataAndType(path2, "application/pdf");
PackageManager manager = getPackageManager();
i = manager.getLaunchIntentForPackage("com.infraware.PolarisOfficeStdForTablet");
i.putExtras(mMWM.makeMultiWindowAppIntent(SMultiWindowManager.FREE_AND_PINUP_STYLE, new Rect(640, 0, 1280, 752)));
i.addCategory(Intent.CATEGORY_LAUNCHER);
startActivity(i);
}
catch (ActivityNotFoundException e) {
}
The polaris window is opening in multiwindow mode but the pdf file I am sending across isnt opening.
Can someone help me understand why the PDF isnt opening and how I can modify my code to get it working?
Thanks;
Andy