Signin/Signup with: 
Welcome, Guest
Username: Password: Remember me
Development and suggestions about third part tool integration.
Cordova, Xamarin, Basic4Android topics are listed here.
  • Page:
  • 1

TOPIC:

Read PDF from SD Card, cordova app 6 years 8 months ago #12741

  • raju1980
  • raju1980's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 4
  • Thank you received: 0
I am trying to read a pdf from Android storage. The physical path as shown by file explorer in android is. storage/emulated/0/"Download/test.PDF.

When I try RadaeePDFPlugin.open => url: "file:///storage/emulated/0/"+"Download/test.PDF".
It gives invalid path error. file:///mnt/sdcard/Download/test.PDF is also not working.
Please help how can I read pdf which is in sd card.

Please Log in or Create an account to join the conversation.

Read PDF from SD Card, cordova app 6 years 8 months ago #12742

  • Davide
  • Davide's Avatar
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 814
  • Thank you received: 65
Hi,
I suggest you to look at this article : www.radaeepdf.com/support/knowledge-base?view=kb&kbartid=84

Please Log in or Create an account to join the conversation.

Read PDF from SD Card, cordova app 6 years 8 months ago #12743

  • raju1980
  • raju1980's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 4
  • Thank you received: 0
url: "file:///mnt/sdcard/Download/Test.pdf"
Is not working same error. It seems like some gap in documentation. I am into the default cordova project provided on github.

Please Log in or Create an account to join the conversation.

Read PDF from SD Card, cordova app 6 years 8 months ago #12744

  • support
  • support's Avatar
  • Offline
  • Administrator
  • Administrator
  • Posts: 692
  • Thank you received: 59
It seems the KB article in someway incorrect or incomplete.

Please, take a look at www.radaeepdf.com/forum/cordova/3699-ope...nternal-memory#12674 we was answering some weeks ago.

Please Log in or Create an account to join the conversation.

Read PDF from SD Card, cordova app 6 years 8 months ago #12755

  • raju1980
  • raju1980's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 4
  • Thank you received: 0
I tried this
url: cordova.file.externalRootDirectory+"Test.pdf",

But it gives same invalid path error. I have installed cordova file plugin and checked it in console. The path is correct.

Any suggestion?

Please Log in or Create an account to join the conversation.

Read PDF from SD Card, cordova app 6 years 8 months ago #12760

  • Davide
  • Davide's Avatar
  • Offline
  • User is blocked
  • User is blocked
  • Posts: 814
  • Thank you received: 65
Hi,
this guide shows you how to open pdf and other functionnality using cordova www.radaeepdf.com/support/knowledge-base?view=kb&kbartid=84
This is an example that shows you how to open from assests : www.radaeepdf.com/forum/cordova/3699-ope...nternal-memory#12674

Are you using device with Android 6.0+?
The problem should be that you don't give the proper permission to read and write from the sdcard, these permission are necessary to open the pdf, this article will help you : developer.android.com/training/permissions/requesting.html

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Powered by Kunena Forum