SilverlightShow: Advanced printing in Silverlight Comments Silverlight articles, Silverlight tutorials, Silverlight videos, Silverlight samples Argotic Syndication Framework 2008.0.2.0, en-US (Emil Stoychev) Re: Advanced printing in Silverlight <p>Hi Jonathan,</p> <p> Is it possible to implement the 'Page Setup' concept like margin alignment before sending it for printing?</p> <p></p> Paran Fri, 22 Jul 2011 17:43:47 GMT RE: Advanced printing in Silverlight <p>Hi Jonatthan! Great article! Many thanks for sharing!</p> <p><a href="">Chrome OS</a></p> Fillipe Tue, 31 May 2011 14:10:12 GMT RE: Advanced printing in Silverlight 4 <p>My solution of fit-to-page Silverlight printing:</p> <p><a href="" target="_blank">Silverlight printing: fit-to-page.</a></p> Jacek Jura Tue, 30 Nov 2010 09:39:52 GMT RE: Advanced printing in Silverlight 4 <p>Hi SC Vinod,</p> <p>You could use the same approach to also account for the width of the page. It's more complex. You would first have to make sure you only display the columns you can fit on the page and then adjust for the amount of records. Then on the second page, you would print the same records, but you would have to print different columns. Then on the third page (assuming it would fit on two pages) you would print the second set of records showing the first batch of columns, etc..</p> <p>It's the same approach, only more complex, because you have the same thing twice, but now impacting each other.</p> <p>HTH.</p> mrjvdveen Thu, 22 Jul 2010 09:26:26 GMT RE: Advanced printing in Silverlight 4 <p>Hi Jonathan,</p> <p>                  Thanks a ton for your reply. I got some ideas on how to print my datagrid. Now the issue that I'm facing is my DataGrid is too wide in width so only 60% of the width of my DataGrid is getting printed. If the height is the problem while printing we can remove the last record and set HasMorePages = true, but what can we do if the width of the page is greater than the width of the PrintableArea? </p> SC Vinod Thu, 22 Jul 2010 09:20:37 GMT RE: Advanced printing in Silverlight 4 <p>@SC Vinod: The approach I demonstrated above is exactly what you need. Just replace the bodyTextBlock in the PrintPage for a DataGrid and remove the footerTextBlock. Then instead of adding text to the bodyTextBlock you should databind a new datasource to the DataGrid and keep adding records until the PrintPage no longer fits on paper and then remove the last record. </p> <p>Keep track of what record you added last and you can continue on the next page. It's really the same algorithm, just with slightly different ingredients.</p> <p>HTH. If you have questions, just let us know.</p> mrjvdveen Wed, 21 Jul 2010 09:31:44 GMT RE: Advanced printing in Silverlight 4 <p>Hi Jonathan,</p> <p>                    I need to print a very long Silverlight DataGrid....When I use PrintDocument Only half of the DataGrid is getting printed... Can you please suggest me a solution....I also need to add a header to my datagrid getting printed. Thanks in advance.</p> SC Vinod Wed, 21 Jul 2010 08:15:00 GMT RE: Advanced printing in Silverlight 4 <p>@Ethan: Wow, you must be eager for an answer :-).</p> <p>Unfortunately there is no way to set the page layout (yet?). A security consideration, perhaps?</p> <p>@Balaji: I'm not sure what you mean, but you can adjust this approach to fit most needs. It's simply a way of preventing a page overload and making sure everything is printed.</p> mrjvdveen Tue, 13 Jul 2010 09:40:10 GMT RE: Advanced printing in Silverlight 4 Is there a way to set page layout t landscape? Ethan Mon, 12 Jul 2010 22:17:29 GMT RE: Advanced printing in Silverlight 4 Excellent example. Just what I was looking for, creating a custom printing template and use it to print multiple pages. Thank you very much Vishal Sat, 10 Jul 2010 19:09:13 GMT RE: Advanced printing in Silverlight 4 <p>hi jonathon </p> <p>Can it be possible to impolement this logic for the xaml with </p> <p>panel bar inside the Grid with many rows and Columns.</p> <p>Can you pls get back </p> <p>Thanks</p> <p>Regards</p> <p>N.Balaji</p> Balaji Mon, 21 Jun 2010 07:43:54 GMT RE: Advanced printing in Silverlight 4 Really nice, just what I was looking for.  Thanks! Chris Bordeman Wed, 09 Jun 2010 07:34:47 GMT RE: Advanced printing in Silverlight 4 <em>Wow!</em> Marnei Wed, 19 May 2010 16:54:50 GMT