<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Code</title><link>https://www.infopathdev.com:443/forums/45.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Code (c#) to print a browser form</title><link>https://www.infopathdev.com:443/forums/thread/52057.aspx</link><pubDate>Tue, 23 Feb 2010 07:05:52 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:52057</guid><dc:creator>shehan</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/52057.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=45&amp;PostID=52057</wfw:commentRss><description>&lt;p&gt;I have a form that thas rendered online on a MOSS 2007 farm. I need to have a button, that when clicked will cause the form to print or at least open up the browsers print dialog screen.&lt;/p&gt;&lt;p&gt;I found a bunch of topics on this in this forum, that talk of using&amp;nbsp; XDocument.PrintOut() and so on, but when I compile it complains that XDocument does not exist in the current context. &lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Can someone please help me with sample C# code to achieve this? &lt;br /&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>