﻿<?xml version="1.0" encoding="utf-8"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:media="http://search.yahoo.com/mrss/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0"><channel><title>Intersoft Community - WebGrid Enterprise - Print complete webgrid data only</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Print-complete-webgrid-data-only/</link><description /><generator>http://www.intersoftsolutions.com</generator><language>en</language><copyright>Copyright 2002 - 2015 Intersoft Solutions Corp. All rights reserved.</copyright><ttl>60</ttl><item><title>Print complete webgrid data only</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Print-complete-webgrid-data-only/</link><pubDate>Thu, 08 Oct 2015 09:21:04 GMT</pubDate><dc:creator>Arief</dc:creator><category>Print</category><category>grid data print</category><category>print only webgrid data</category><description>Hi Rupesh,&lt;br&gt;&lt;br&gt;Sorry for the late response here is what I do:&lt;div&gt;Note that I'm using Allow Print in web grid samples and make a new button as a demonstration, I add the function ExportHTMLAndPrint().&lt;/div&gt;&lt;div&gt;&lt;br&gt;here is my js&lt;/div&gt;&lt;div&gt;&lt;pre&gt;var isPrint = false;      &lt;br&gt;  function ExportHTMLAndPrint()        {
            var WebGrid1 = ISGetObject("WebGrid1");
            isPrint = true;
            WebGrid1.ExportGrid("", "HTML", "PORTRAIT");
            
        }
        function OnExportPrintResponse(controlId, status) 
        {
           var grid = ISGetObject(controlId);
            if (isPrint) {
                var fileLocation = ISXml.GetNodeText(grid.XmlResp, "//outputFile");
                var iFrameWindow = document.getElementById("printFrame");
                if (!iFrameWindow) {
                    iFrameWindow = document.createElement("iframe");
                    iFrameWindow.id = "printFrame";
                    iFrameWindow.style.display = "none";
                    document.body.appendChild(iFrameWindow);
                }
                iFrameWindow.src = fileLocation;
                debugger;
                if (iFrameWindow.contentWindow.print) {
                    iFrameWindow.onload = function () { iFrameWindow.contentWindow.print() };
                }
                else {
                    iFrameWindow.onload = iFrameWindow.contentWindow.document.execCommand("print", false, null);
                }
                grid.SetStatus1("", "ready", "CommonText/Ready");
                return false;
        }&lt;/pre&gt;&lt;p&gt;&amp;nbsp;and here is my client side event I intercept the OnResponse&lt;/p&gt;&lt;pre&gt;&amp;lt;ClientSideEvents OnResponse="&lt;span style="font-size: 9pt;"&gt;OnExportPrintResponse&lt;/span&gt;&lt;span style="font-size: 9pt;"&gt;" /&amp;gt;&lt;/span&gt;&lt;/pre&gt;&lt;p&gt;The result is whenever you press the button it will automatically show print pages using export to HTML.&lt;br&gt;Hope this will help!&lt;/p&gt;&lt;/div&gt;
&lt;pre&gt;&lt;/pre&gt;</description></item><item><title>Print complete webgrid data only</title><link>http://www.intersoftsolutions.com/Community/WebGrid/Print-complete-webgrid-data-only/</link><pubDate>Tue, 06 Oct 2015 09:10:20 GMT</pubDate><dc:creator>rupeshshakti</dc:creator><category>Print</category><category>grid data print</category><category>print only webgrid data</category><description>&lt;p&gt;Hi,&lt;/p&gt;&lt;p&gt;&lt;span style="font: 13px/19.5px &amp;quot;Lucida Grande&amp;quot;, &amp;quot;Lucida Sans Unicode&amp;quot;, Helvetica, Arial, Verdana, sans-serif; text-align: left; color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; widows: 1; font-size-adjust: none; font-stretch: normal; background-color: rgb(255, 255, 255); -webkit-text-stroke-width: 0px;"&gt;Is there any features to print only the complete&amp;nbsp;grid data without exporitng the data in excel or csv?&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style="font: 13px/19.5px &amp;quot;Lucida Grande&amp;quot;, &amp;quot;Lucida Sans Unicode&amp;quot;, Helvetica, Arial, Verdana, sans-serif; text-align: left; color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; widows: 1; font-size-adjust: none; font-stretch: normal; background-color: rgb(255, 255, 255); -webkit-text-stroke-width: 0px;"&gt;&lt;/span&gt;&lt;span style="font: 13px/19.5px &amp;quot;Lucida Grande&amp;quot;, &amp;quot;Lucida Sans Unicode&amp;quot;, Helvetica, Arial, Verdana, sans-serif; text-align: left; color: rgb(51, 51, 51); text-transform: none; text-indent: 0px; letter-spacing: normal; word-spacing: 0px; float: none; display: inline !important; white-space: normal; widows: 1; font-size-adjust: none; font-stretch: normal; background-color: rgb(255, 255, 255); -webkit-text-stroke-width: 0px;"&gt;&amp;nbsp;I am in need to have a menu-option of print from within the grid that prints the complete&amp;nbsp;grid data.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;I had chat conversation with your support team(Jolis and Arief) they &amp;nbsp;suggest to set AllowPrint to in Webgrid layout.&amp;nbsp;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;As My requirement is need to print all webgrid data, I disabled the paging and loaded all the records(around 10000).&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;once I hit the print command from webgrid it takes too much time to print the data into pdf(for testing) and following problem(attached) in print layout:&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;1. First column is not rounding properly, it is cutting.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;2. Some blank space after rows.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;3. overlapped the data.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;all the above issue you can see in attachement.&amp;nbsp;&lt;/span&gt;&lt;img id="" src="https://www.intersoftsolutions.com/assets/images/legacy/smiley11.gif" style="font-size: 10pt; border: none;"&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;waiting for your reply ASAP.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;Thanks&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;Rupesh Shakti&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span color="#333333"&gt;(Software Engineer)&lt;/span&gt;&lt;br&gt;&lt;/p&gt;</description></item></channel></rss>