View Full Version : Print functionality in Grid

14 May 2010, 5:51 PM
I have a grid that shows 10 line items per page. I need to add a print button that will open another page with all rows rendered and showing just the grid. Any ideas how I would do this ? Is there functionality already built into the grid ?

15 May 2010, 5:32 AM
I am surprised that such an extensive library does not have support for what is a very common functionality. Didnt anyone face this issue before ? Any suggestions ?

15 May 2010, 4:47 PM
there are a couple of so so print solutions in the forum for extjs. None are great, I assume they will work for gxt.

15 May 2010, 5:14 PM
Thanks for your reply moegal. I looked at the following discussion :


I am not sure how the extjs user extensions will work with GXT or even if it can be used along with GXT widgets. Assuming I could simply put those html and js files on my class path, how would I trigger the print functionality ? Is there anything coming up in the future releases of GXT for print functionality ?

16 May 2010, 3:46 AM
good luck, I am using the Print Element version in extjs with some luck. But it prints light in IE and screws up the layout in FF after the print icon is clicked.


16 May 2010, 4:23 AM
did u have to customize the extjs solution to work with GXT grids ? If not, what are u doing inside the clickhandler for the print button/link.. in other words, how are u calling the js function and passing in the store instance for it to be able to print the entire grid ?

16 May 2010, 6:01 AM
sorry not gxt. And sadly no, I am using paging grids and this will print only the records returned from each page and not the entire collection.

16 May 2010, 9:55 AM
Thanks for your reply Marty. I am using GXT and struggling to get the print functionality working. Its just soo sad that such a common functionality is not supported with GXT or extjs out of the box ... or some kind of generic print functionality that can be extended..... is there anyone in this community who had the same issue with printing ?