Forum


14:20

11/03/2010

hi,
var grid = jQuery("#" + currenttablename);
grid.editGridRow(......
After I use the editGridRow() to show an edit dialog, when I close it, the jqgrid will append a <DIV id ='editmod' +currenttablename > in to the jgrid.
I don't know what's this div's usage, and this will cause a problem when I try to print the jgrid.
The problem is happened when the jggrid's row include an edittype:textarea, it seem that in the <DIV id ='editmod'> it create an <TEXTAREA..... . That unforunetely config with the jquery.printElement.js, which is a print plugin, you could find it on the jquery web-site.
So I have to remove the <DIV id ='editmod'> to run print.
I don't found any problem after I removed the <DIV id ='editmod'. the jqgrid could show/load/edit data as usually.
Please tell me if it will cause any problem I don't know, if I just removed the <DIV id ='editmod'> created by the editGridRow().
yours,
Ivan
14:49

10/08/2009

I recommend you don't remove any divs which you find on the page. Instead of this you can use
See an additional CSS with media="print" like
<style type="text/css" media="print"> #editmod { display:none } </style>
See http://stackoverflow.com/quest.....69#2962569
Regards
Oleg
18:20

10/08/2009

You written that you want to print a grid. Aren't you? If you search for jquery.printElement.js (see http://github.com/erikzaadi/jQ.....Element.js) for the text editmod you will find nothing. So there are no conflicts between jquery.printElement.js and jqGrig, form editing. I not really understand why you need use any plugin to print your web page. What you really need is a CSS for the "print" media. It defines which elements and how should be displayed on the print media (what should be printed).
Removing of a a DIV with id = 'editmod' + gridid if you want to print a grid I find absolutely unlogical. It is like a suggestion to break windows if you want to go throuth the door of the hauses. Sorry.
Moreover I recommend you to read http://www.trirand.com/blog/?p.....id/#p18449 which it about the same problem.
05:18

11/03/2010

jquery.printElement.js use a textarea internally, so if the grid has a textarea edit type, it will create a textarea in the editmod code part, which will confilct with the jquery.printElement.js.
I Use the plugin to print, is because it's much more easier to print a element, like a div. Of cause, we can use media=print + css to do everything. But plugin will help us to do it better.
yours,
Ivan
Most Users Ever Online: 715
Currently Online:
60 Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
OlegK: 1255
markw65: 179
kobruleht: 144
phicarre: 132
YamilBracho: 124
Renso: 118
Member Stats:
Guest Posters: 447
Members: 11373
Moderators: 2
Admins: 1
Forum Stats:
Groups: 1
Forums: 8
Topics: 10592
Posts: 31289
Newest Members:
, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.comModerators: tony: 7721, Rumen[Trirand]: 81
Administrators: admin: 66