Android Question Google Cloud Print Question

tdocs2

Well-Known Member
Licensed User
Longtime User
Greetings, all.

Thank you in advance for your replies.

I create a text file (.txt) where I have inserted pagebreak characters (Chr(12)). The intent would be to print multiple pages from one txt file. The pagebreak character is inserted at the desired page break. I am using Google Cloud Print. (The same result with hp_ePrint).

It did not work. Does anyone know how to achieve this?

Best regards.

Sandy
 

DonManfred

Expert
Licensed User
Longtime User
Does anyone know how to achieve this?
Archieve what? I did not find a question in your post.
BTW: what is chr(12) ?

A Carriage Return is chr(13) and a line feed is chr(10). Usually both together are on the end of a line...
 
Upvote 0

tdocs2

Well-Known Member
Licensed User
Longtime User
Archieve what? I did not find a question in your post.
BTW: what is chr(12) ?

A Carriage Return is chr(13) and a line feed is chr(10). Usually both together are on the end of a line...
Hello, Don.

Chr(12) is a Page Break.

I will try to clarify my question by using an example:

I want to create a txt file with 10 lines. Each line ends with CRLF. I want each line to print on a separate page.

I hope this is clearer.

Thank you.

Sandy

PS Wikipedia Page break
http://en.wikipedia.org/wiki/Page_break
 
Last edited:
Upvote 0

mc73

Well-Known Member
Licensed User
Longtime User
Not sure that 12 could work.
I would choose to insert a delimiter, then regex.split and send each string of the array as a separate file/string. Guess this would work :)
 
Upvote 0

tdocs2

Well-Known Member
Licensed User
Longtime User
Not sure that 12 could work.
I would choose to insert a delimiter, then regex.split and send each string of the array as a separate file/string. Guess this would work :)
Thank you, mc.

Precisely, this is not what I want to do. I want a single file. Otherwise, the user would have to print each file individually. I used 10 lines as an example, but it could be 400...

If Chr(12) does not work, then what would?

Thank you and best regards.

Sandy
 
Upvote 0

mc73

Well-Known Member
Licensed User
Longtime User
Even though I don't understand what's the meaning of 'user has to print' since it's your app that should take care of pages' separation, another suggestion is to convert your txt to a html page, then apply page breaks, using css for instance.
 
Upvote 0

tdocs2

Well-Known Member
Licensed User
Longtime User
Thanks again, mc.

I have little or no experience printing in Android.

I basically create a file, txt or xls where the user can choose the file via ES File Explorer or another means, and then chooses to print via the app like WPS Office or through HP-ePrint (which has become stagnant) or Google Cloud Print. I know how to print on Windows VB, but not on Android. I was hoping for NJDude to update his Cloud Print to include 4.4, but he has not :(. (And as I write, I am updating my Nexus 10 to 5.0).

My target users will live in a pure Android world - no PC's with Windows - just Android tablets, a wireless router, and wireless printer (Cloud enabled).

Any suggestions? I will be most appreciative.

Best regards.

Sandy
 
Last edited:
Upvote 0
Top