still interested if you have an advice
Why not use FlexPrintJob and PrintDataGrid?
I didn't know FlexPrintJob, with PrintDataGrid that is what I needed.
Not easy to make it work because I had to wait for BitmapImage to be ready to add the view to the printJob, and also handle layout problems so the PrintDataGrid actually print multiple pages...
But it works now, thanks.
Maybe you can help me on this : when the page is printed, the PrintDataGrid appears to be too big, each row could be twice as small. Is it a resolution problem, is there an option to avoid this ? (same problem with the example at http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/mx/printing/PrintDataGr id.html#includeExamplesSummary )
I tried to change the page height to bigger value than printJob.pageheight but then each page of the PrintDataGrid is printed on several pages.
Try the rowHeight property on the PrintDataGrid
No, all elements in the page are big, it is not a rowHeight problem, the text is big too (like if it was a 14 or 16 font size). If I reduce the rowHeight I don't see the text in cells.
As if the resolution was too small.
There are scaling options on FlexPrintJob.
I noticed this line in the doc :
Note: A point is a print unit of measurement that is 1/72 of an inch. Flex automatically maps 72 pixels to one inch (72 points) of printed output, based on the printer settings.
I don't really understand but I suppose that means FlexPrintJob.pageHeight and FlexPrintJob.pageWidth will always return values according to 72dpi.
I managed to have a 96dpi that reduce the components in my page :
myPage.width = 756;
myPage.height = 1085;
Then if I don't set scale option, it prints the page and a blank page follows. To make it work ok, I have to do :