Hi,

I want to display some data on webpage using 
"google.visualization.Table()". The table is being displayed perfectly for 
small amount of data. But for more number of rows, I want to add paging in 
the table. For that I have added " page:[enable], pageSize:[20] " options 
while using draw() method. Now, table is displaying with paging as per the 
options (20 rows per page) and paging button is also displayed but those 
buttons are not working.

Actually I'm new to Google Visualization Chart. Can anyone help me, how to 
start working those buttons? 

Below is the code snippet which I've used.

Please let me know if any further information is required.

Thanks,
Chetan

//chartClickData is in JSON Format
function (chartClickData) {

 
                                var dataT = new 
google.visualization.DataTable();
 
                                // Declare columns
                                dataT.addColumn('string', 'DateTime');
                                dataT.addColumn('number', 'TimeElapsed');
                                dataT.addColumn('string', 'RemoteHost');
                                dataT.addColumn('string', 'Code');
                                dataT.addColumn('number', 'StatusCode');
                                dataT.addColumn('string', 'Meaning');
                                dataT.addColumn('number', 'Bytes');
                                dataT.addColumn('string', 'Method');
                                dataT.addColumn('string', 'URL');
                                dataT.addColumn('string', 'PeerStatus');
                                dataT.addColumn('string', 'PeerHost');
                                dataT.addColumn('string', 'Type');
 
                                for (var i = 0; i < chartClickData.length; i++) 
{
                                  dataT.addRow([chartClickData[i].DateTime,
                                    chartClickData[i].TimeElapsed,
                                    chartClickData[i].RemoteHost,
                                    chartClickData[i].Code,
                                    chartClickData[i].Status.StatusCode,
                                    chartClickData[i].Status.StatusMeaning,
                                    chartClickData[i].Bytes,
                                    chartClickData[i].Method,
                                    chartClickData[i].URL,
                                    chartClickData[i].PeerStatus,
                                    chartClickData[i].PeerHost,
                                    chartClickData[i].Type]);
                                }
 
                                var table = new 
google.visualization.Table(document.getElementById('Tablediv'));
 
                                var options = {
                                    alternatingRowStyle: [true],
                                    showRowNumber: [true],
                                    page: ['enable'],
                                    pageSize: [8],                              
     
                                };
 
                                options['pageSize'] = 8;                        
        
 
                                table.draw(dataT,options); 

                            }

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-visualization-api/ed195843-2bc6-40fd-888d-d0a3c6618964%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to