Page 2 of 6

How to do print currnt page when click on Print button.

Posted: Fri Jan 31, 2014 11:55 am
by navya kodali

yes i have downloaded plugin from this link.
and added to my project in apprey.io as per documentation provided in apprey.io.


How to do print currnt page when click on Print button.

Posted: Fri Jan 31, 2014 3:06 pm
by Maryna Brodina

In plugin description there is a section "Using the plugin" - follow instruction to invoke plugin.


How to do print currnt page when click on Print button.

Posted: Mon Feb 03, 2014 7:04 am
by navya kodali

HI,
I have used that code in button click.after i export my project into xcode project.
but there is no plugin in project foder structure. print functionality is not woking.


How to do print currnt page when click on Print button.

Posted: Mon Feb 03, 2014 4:30 pm
by maxkatz

Appery.io doesn't have any special print features. You should use any standard browser APIs available for printing or see if there is a PhoneGap plugin.


How to do print currnt page when click on Print button.

Posted: Wed Feb 05, 2014 10:01 am
by navya kodali

ya i have verified phonegap plugin.it is also like cardova plugin.
Just let me know one thing after added 3rd party plugin.that plugin color will be in black color or blue color.
I have added phonegap plugin also in apprey.io
When i exported into xcode project it is not presented in project folder.


How to do print currnt page when click on Print button.

Posted: Wed Feb 05, 2014 12:56 pm
by Kateryna Grynko

Hi Navya,

Files and folders added and changed manually will be highlighted with blue. They must be. Where did you add them, in what folder? Where did you search for them?


How to do print currnt page when click on Print button.

Posted: Wed Feb 05, 2014 1:24 pm
by navya kodali

In source-select IOS-first folder with project name-cordovalibplugins-click on settings button-upload to this folder-select zip bundle-drop there downloaded zip file.

after that click on save to test in device click on export-select xcode project-savefile-unzip the folder-open project.

There is no added plungins.

If i add manually to this project it does not work.

Anything need to do in terminal(command prompt in windows) to work with it?


How to do print currnt page when click on Print button.

Posted: Wed Feb 05, 2014 8:22 pm
by Maryna Brodina

Hello!
1) "Anything need to do in terminal(command prompt in windows) to work with it?" - no
2) "There is no added plungins." - did you that files are added in builder on Source tab (blue colored files)

Could you post screenshot so we can see what you have in builder on Source tab and screenshot of project source files content (where should be added folder with plugin, but it's not)?


How to do print currnt page when click on Print button.

Posted: Sat Apr 19, 2014 3:14 pm
by Asif

Hi Maryna,
I am also using same plugin for printing from Android phone.
I have added the plugin in my appery project using the instructions on your website.

On the plugin git site they have given following code to invoke printing on the page
code
// Get HTML string
var page = document.body.innerHTML;

// Pass the HTML
window.plugin.printer.print(page);
/code

I have written this code as JS on the click of a button, but when i click on the button, nothing happens.

Pls help!!

Or if you have any other way to print from android app pls let me know.


How to do print currnt page when click on Print button.

Posted: Sat Apr 19, 2014 9:36 pm
by Igor

Hello,

Could you check logcat logs to see if there any errors when you are trying execute this code?
http://developer.android.com/tools/he...