Printing problem

Is there any way you can set a method to print the first page of a document to one paper tray (i.e. letter head) and the remaining pages to another tray (i.e. plain paper).

This would be very useful for printing multipage invoices, form letters etc?

Any ideas?

Chris

This is not possible, the java printing API’s from SUN does not support this action… :(

This are very, very bad news.

My customers print about 1000 - 3000 invoices every 1. of a month with 1 to 50 pages each (now in FileMaker, but we want change to Servoy).
The first page should be printed on letter head and the other on plain paper. How can this be done. You donM-4t mean that anyone shall sort this?

Sorry, but if thereM-4s no possibility I canM-4t sell my solution to them.
And IM-4m very sad to say this.

Jan, is there a way, to assign print-jobs to different printers?

I have asked this feature for a while ago, don’t know where it is on the wishlist!

Like for instance you than install 2 printer drivers pointing to the same printer. One with the default paperfeed 1 and one with the default paperfeed on 2

We also have software, which is not compatible with such feature , and always solved it, this way.

Just thinking!

Thanks for your suggestion HJK, I think that whould work…the only question remains where to store default form printer info?

I think there are 3 options:
1)in the form (not handy when selling to multiple customers having different printers)
2)in the client properties (every end user has to set the default printer per form)
3)in a (separate) property file downloaded by client and editted by developer on the server, containing something like:
printer.crm=hpLJ1000
printer.crm.orders=hp2200
where the first line is the default printer and the second line an exeption for a form

In my opinion option 3 is the best we could provide… in this case WiderGates can print the first page via a form (and specific printer) followed by the other pages via other form (and other printer)

Let us know your thoughts.

3)in a (separate) property file downloaded by client and editted by developer on the server, containing something like:
printer.crm=hpLJ1000
printer.crm.orders=hp2200

But how to handle if the client, is at the other side of the world?
Can you use that property file in a method?
Does it work, if I do a print-preview first and than push the print-button?

I think it would be handy, that if a standard printer (in such file) is not found, that there will be an error-message to catch, you than can provide a method that opens the standard printer-dialog, with the local printer of the client?

Our ‘solution’ is to place hi res colour jpg/gif images of the stationery header and footer on the first page header and first page footer of the relavant forms - e.g. estimates, invoices, purchase orders etc.

In a general solution, this can be done by having these images stored in media fields - so it makes it easy to update for each client.

Then the clients print to a colour printer.

Since you can now get a decent networkable colour laser for less than 1500 Euro and the running costs are not too high, this actually works out cheaper than using pre-printed letter head - unless you are talking very high volume.

An added advantage of this is that you can use the same method and form to print to a PDF and email the printed output - thus saving paper (although the receipient will probably still print it out) and postage costs.

Probably not the ideal solution for everyone, but works for us.

Chris

My colleague Jan Aleman had an even better Idea, we add a function controller.setPreferredPrinter(name) which the developer can use to set a prefered printer by name, so the developer can get/store the printer names where he wants (ie. database table/server file retrieved via url) and set the name when he thinks fit the need, based on (security) user group based on office locations etc.

HJK:
Does it work, if I do a print-preview first and than push the print-button?

For this you whould need ‘onPrintCmd’ on a form I guess?

WONDERFULL! :!: :D

onPrintCmd would certainly do the trick! I think.

Than we also need: getPrinters()?
Or am I wrong?

controller.setPreferredPrinter(name) will be availeble in Servoy 2.0 rc8

Than we also need: getPrinters()?

whould only deliver the local machine printer names which is of almost no use in large companies with printer for each department…

Anyone know how to import grahpics/images (jpg/gif/png) and get them to print at more than 72dpi???

I need to have a client logo printed on a layout at a decent (300dpi) resolution.

Ta

Chris

set form property printScale to 400% to print ~300dpi (normal = 72 dpi)

Doesn’t this mean you have to scale everything on the page by 4x?

This would be a real pain since I have to redo all my print layouts.

Let me know.

I think getPrinters would still be useful, even if it only lists the printers a user has configured. But combined with the other possibilty, we could offer a user “his” printers in a valuelist, store that in a table and use it later with setPreferredPrinter(name).

I agree with Patrick!

cjemichael:
Doesn’t this mean you have to scale everything on the page by 4x?

What else whould you expect?, or are you suggesting that we should print scaled images (cropped on a label) with a higher resolution? (which is possible)

I think the most useful solution would be if you could either specify the scaling/resolution of images (as an image property) OR if the resolution was determined by the image automatically (e.g. if you place a 600dpi image on the form, then it prints at this resolution).

I imagine many users would want to add graphics (e.g. logos) to forms for say invoices. To scale the whole form up by 400% to get hi res output is a lot of work and does not seem logical.

will be availeble in Servoy 2.0 rc10

Jan, does this mean this is implemented for images only?
or text, labels etc, too?

highres. image printing is availble for all scaled images