tags:

views:

430

answers:

1

I have a jqgrid sitting on my screen that displays about 3500 records as a result of a search. I am using paging and user only sees about max 45 records at a time. I want to create a functionality to print grid data (all 3500 records). To do so I am creating another view that I can go to via a controller and it would generate the same result as the jqgrid but will show as an html table. So the users can use the browser print functionality to print the results.

From the screen I can obtain all the information to send to the print controller, even the sortorder and sortId but if the user used the jqgrid search functionality to further filter the result I would like to retrieve that detail from the grid so when I call the print functionality I can recreate the results.

My question is do I have the right approach to print jqgrid data or is their a simpler way. If I do have the right approach then I need the searchfilter information from the jqgrid and I do not know how to retrieve those values, sValue, sField, sOper.

Thank you

A: 

add a custom image e.g. "print" image and add to jqGrid. Link the image to the controller and try accessing the grid parameters like sValue

Your controller action should accept all parameters like sValue, SField etc.. give it a shot !!

--Vikas :)

Vikas
Great suggestions Vikas, I have already tried that. Items like search, sidx, and sord has value but sValue, SField and sopt comes out to null.Do you know how to get access to the Search parameters on the JQGrid.Thanks,Sadia
Sadia