Open antbucc opened 9 years ago
Have you stepped thru the code w/ a debugger? Do you have any more info on what happens when clicking generate?
I have the same problem, first thing I notice was this
I/chromium( 6324): [INFO:CONSOLE(21)] "Uncaught ReferenceError: $cordovaFile is not defined", source: file:///android_asset/www/js/app.js (21)
And after that
I/chromium( 6324): [INFO:CONSOLE(44)] "ReportCtrl: Opening PDF File (file:///storage/emulated/0/rptSample.pdf)", source: file:///android_asset/www/js/controllers.js (44) I/chromium( 6324): [INFO:CONSOLE(19387)] "ReferenceError: hideLoading is not defined I/chromium( 6324): at file:///android_asset/www/js/controllers.js:46:21 I/chromium( 6324): at processQueue (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:20962:27) I/chromium( 6324): at file:///android_asset/www/lib/ionic/js/ionic.bundle.js:20978:27 I/chromium( 6324): at Scope.$eval (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:22178:28) I/chromium( 6324): at Scope.$digest (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:21994:31) I/chromium( 6324): at Scope.$apply (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:22282:24) I/chromium( 6324): at file:///android_asset/www/lib/ionic/js/ionic.bundle.js:24008:36 I/chromium( 6324): at completeOutstandingRequest (file:///android_asset/www/lib/ionic/js/ionic.bundle.js:12714:10) I/chromium( 6324): at file:///android_asset/www/lib/ionic/js/ionic.bundle.js:13094:7", source: file:///android_asset/www/lib/ionic/js/ionic.bundle.js (19387)
'...$cordovaFile is not defined...' is an indication that the File plugin is not available. Did you add the File plugin to allow working w/ files on the device?
cordova plugin add org.apache.cordova.file
Please take a look at the section on plugins used and make sure all of these plugins are installed and retry.
Hello!
I think my problem was other stuff and get fixed with this http://stackoverflow.com/questions/33970789/cordovafile-not-defined-ngcordova-plugin
Thank You!
In android the pdf view is not displaying, Its just displaying blank page. When i open the pdf from file manager path it opens.
What seems to be the problem? why its not getting displayed in app?
@surajde16 do you have a pdf viewer installed on the android device? I know that android does not have a default pdf viewer like the one built into safari on ios. So, perhaps you need a pdf viewer. The other issue could be the way in which my code opens the pdf. I don't do a great deal of android work, so it may be that the pdf viewer is there, by my code does not open the file properly to have it opened by the viewer. I know that there was a separate issue (#3) posted about android viewing. The fix in that issue was related to switching to use fileopener2 plugin for opening the PDF.
Give these a look and let me know if it helps. Thanks.
Hi, I have downloaded it but does not work. When I click on "Generate" no pdf file is create. What should be the problem?
Thanks Antonio