Categories | Question details Back To List | ||
Smart Rendering with dhtmlXGridFromTable Hallo everybody, I'll try to explain the problem i have with the dhtmlXGridFromTable fonctionnality and hope i'll find an answer by you I have a table with big dataset and i have used dhtmlXGridFromTable functionnality with smart rendernig to have better performance. So far it's OK. Each line of the table have à column with checkbox and the header of the table have a master checkbox, the problem is when i check the master checkbox only the visible lines are checked, when i scroll down the table the new lines that appeared aree not checked. Is there any function that let the table show all the lines without scrolling ? so i can combine this without missing the smart rendering performance enhancement. Thanks a lot for your help und forgive my poor english. Answer posted by Support on Sep 14, 2009 09:14 To prerender all rows in the grid, you can use for ( var i=0; i<mygrid.getRowsNum(); i++) mygrid.render_row(i); Also, you can check the custom "master checkbox" modification, which must work correctly in your case http://dhtmlx.com/docs/products/kb/index.shtml?cat=search&page=1&q=4699&ssr=yes&s=master%20checkbox%20getRowsNum Answer posted by Soufiane Jhioui on Oct 01, 2009 06:12 Hallo, First, Thank you for the prompt response. The solution with : for ( var i=0; i<mygrid.getRowsNum(); i++) mygrid.render_row(i); give me a half solution to my problem. Indeed the checkbox are now all checked but the rows are still invisible till i scroll down the table. The problem is that, the entire grid is a form and the selected lines are sent to the server. So when i have a table and i check the master checkbox only the visibles lines are sent. When i scroll down the table more lines appears (the checkbox is checked => OK) and in this case they are sent. What i want to do when possible, is to let the table really show ALL it's rows (They will be visible even if i don't scroll down the table). i think only in this case will all my rows be sent to the server. Is there any function that let the tables really render it's rows ? Is there any function that let me now if a row with index X is rendered or not ? Is there maybe another solution to thhis Problem without desactivate smart rendering, or it's not possible at all ? Thank you for your help Answer posted on Oct 01, 2009 07:09 >>Is there any function that let the tables really render it's rows ? You should not use smart rendering mode. If you will not use smart rendering mode all rows will be rendered at once. >>Is there any function that let me now if a row with index X is rendered or not ? You can use "onRowCreated" event. This event occurs after a row was created in the grid, and was filled with data. Please find more information here http://dhtmlx.com/dhxdocs/doku.php?id=dhtmlxgrid:event_onrowcreated >>Is there maybe another solution to thhis Problem without desactivate smart rendering, or it's not possible at all In smart rendering mode only those rows are rendered that are in the visible area. If you want all row to be loaded you should disable smart rendering mode. Answer posted by Soufiane Jhioui on Oct 01, 2009 08:09 You should not use smart rendering mode. If you will not use smart rendering mode all rows will be rendered at once. That is the heart of the problem. The goal is to combine Smart Rendering with the possibility to show all lines once the checkmaster checked. The lines are normaly somewhere in the cache are they are rendered without reconnect to server, also i think it must be a function that maybe simulate table scrolling and let the table show the lines. the function render_now() is the first step i think. |