Advertisement
hman

phonegap and cordova.plugins.disusered.open

Oct 10th, 2015
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function view_pdf()
  2. {
  3.     console.log("pdfbutton button clicked");
  4.  
  5.     cordova.plugins.disusered.open(
  6.         'file:/sdcard/Download/test.pdf', view_success, view_error);
  7.  
  8.     console.log("after open");
  9. }
  10.  
  11. function view_success() {
  12.   console.log('Success');
  13. }
  14.  
  15. function view_error(code) {
  16.   if (code === 1) {
  17.     console.log('No file handler found');
  18.   } else {
  19.     console.log('Undefined error ' + code);
  20.   }
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement