jQWidgets Forums
jQuery UI Widgets › Forums › Grid › Grid aggreate width will not auto adjust
Tagged: datagridview paging
This topic contains 5 replies, has 2 voices, and was last updated by Peter Stoev 10 years, 11 months ago.
-
Author
-
I still have 3 troubles: I upload the sample codes: http://jsfiddle.net/QT3Ly/7/
1) the aggregates columns’s width is not adjusted when set the column width to be autoresizecolumns
2) If there are tabs:
Export CSV button in the first tab and JqxGrid is in the 2nd tab. If I don’t click on 2nd Tab, export button will not work.
TypeError: this.columns.records is undefined
It looks like I have to click on 2nd tab to initial Grid before I can click on “Export” button. Is there a way to fix it?3) The JQXGrid page section, “Go to page” section doesn’t seem to work correctly.
Thank you.
Hi shunnan,
1. The “autoresizecolumns” method ensures that the Cells and Header Text will be visible. However, this is not valid for the Aggregates. An option for you would be to set the column’s width property.
2. To create and render custom column aggregates, please look at this example: http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/customaggregates.htm?arctic
3. In Tabs, create the Grid within the initTabContent method of jqxTabs – see the Integration with other widgets demo on our webiste.
4. You can’t export something which is not yet initialized. The Grid is initialized when it is displayed. If it is not displayed, it is not created and so you can’t export it.
5. The method’s name is “gotopage” and it works correctly. See: http://jsfiddle.net/jqwidgets/tYPyV/Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.com/Thank you for your quick reply.
1) Is there a way to initialize Grid without displaying it.
In your example http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxtabs/index.htm#demos/jqxtabs/integration.htm
You initialize the grid when displaying it. My goal is to show the chart first and allow the user to export the data without click on data tab.
2) “gotopage” doesn’t show up correctly. In your example http://jsfiddle.net/jqwidgets/tYPyV/, please try to put ’60’ into the input box and hit enter. You will see the page jumps to 50. It seems to me that last section “xxx-xxx of 500” is 10 times the “Goto page” input box.1. The example demonstrates an approach for integrating widgets within jqxTabs. It does not matter whether the Grid is in the first or 100th tab if you use that approach.
2. Pages are 50. The text is Go To Page, no Go To Record.Best Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.com/1) I updated http://jsfiddle.net/QT3Ly/11/ to use initTabContent. However I still have to click on “data” tab before I can click on “Export CSV” button in tab1. The point here is how to initialize Grid without display it. Is it possible?
2) Thank you for clarify the goto page. I was confused by the last section. It is record #, not page number. Is it possible to show “RowNumber” in the first column without manually add index column? something like grid option:{ showRowNumber: true}Hi Qdkid,
– It is not possible to initialize the Grid, if it is not displayed. The Grid is created when it is displayed. Otherwise, it would not be initialized and so would not consume any web resources.
– The other paging options are: http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/pagingmodes.htm?arctic and building custom paging UI – http://www.jqwidgets.com/jquery-widgets-demo/demos/jqxgrid/custompager.htm?arcticBest Regards,
Peter StoevjQWidgets Team
http://www.jqwidgets.com/ -
AuthorPosts
You must be logged in to reply to this topic.