Hi!I had a igGrid widget working but the resize feature stopped working in some version of our git-svn. It worked before so it shouldn't be a problem of versions.
The thing is I spent a whole afternoon reviewing svn versions and there is no change to the igGrid code, so I guess it should work.
The infragistics used version is the 13.2.20132.2012 (I guess that's the version), and the code is the following one (just the needed things)...
<script type="text/javascript" src="/P/lib/ig2/i18n/infragistics.datasource-en_us.js"></script><script type="text/javascript" src="/P/lib/ig2/i18n/infragistics.ui.combo-en_us.js"></script><script type="text/javascript" src="/P/lib/ig2/i18n/infragistics.ui.editors-en_us.js"></script><script type="text/javascript" src="/P/lib/ig2/i18n/infragistics.ui.grid.framework-en_us.js"></script><script type="text/javascript" src="/P/lib/ig2/i18n/infragistics.ui.upload-en_us.js"></script>
<script type="text/javascript" src="/P/lib/ig2/infragistics.util.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.shared.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.datasource.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.templating.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.combo.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.editors.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.framework.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.rowselectors.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.selection.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.paging.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.sorting.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.hiding.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.updating.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.resizing.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.featurechooser.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.grid.columnfixing.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.scroll.js"></script><script type="text/javascript" src="/P/lib/ig2/infragistics.ui.upload.js"></script>
(yes, there are more things apart from the igGrid)
The following code is the Javascript code:
var igGridFeatures = [];
igGridFeatures.push({ name: "Resizing", deferredResizing: false, allowDoubleClickToResize: true, columnSettings: [ { columnKey: "_toolColumn", allowResizing: false }, { columnKey: "_flagColumn", allowResizing: false } ] });
var feat = { name: "ColumnFixing", columnSettings: [ ] } feat.columnSettings.push({ columnKey: "_toolColumn", isFixed: true, allowFixing: false }); feat.columnSettings.push({ columnKey: "_flagColumn", isFixed: true, allowFixing: false }); igGridFeatures.push(feat);
var col = self.options.data.columns.length; // it's used inside another widget. this is a number var colWidth = 150; var tableWidth = col * colWidth;
// the gridDOM element is a <dd> with a table inside.
gridDOM.find('table').igGrid({ defaultColumnWidth : colWidth, autoGenerateColumns: false, columns: self.options.data.columns, dataSource: self.options.data.grid, type: 'json', features: igGridFeatures, width: "auto" });
The table is displaying the grid correctly because other functions like display data and the fixed column work (so we can assume the columns and dataSource are correct), but the resize is the only thing not working.
Anyone have any idea of why this is not working?
Hello Daniel,
thank you for contacting us. I noticed in your code that allowResizing property in the columnSettings is set to false, which disables the resizing feature of the igGrid.
Please set it to true and let me know if it is working now.
Best regards,Yana DimitrovaDeveloper Support EngineerInfragistics, Inc.
Thanks for your reply.
As you pointed out, there are 2 columns with the resizing option set to false, and that's ok. The problem is the rest of the columns can't be resized either.
can you please send me the whole project, so that I will be able to run it and test it on our side. I also need to know how you are initializing the grid. Are you setting "id" to the table element that is used to initialize it? Please note that the table element, that the grid is initialized through, should contain id atrribute which will be used with jQuery selector attached to the igGrid widget.
Thanks again for your reply.
I can not send the whole project (because of company privacy policies and because it would weight around 100mb.), but I will try to provide a minimum example to reproduce the needed enviroment.
Anyways, as I said in the original post, the igGrid table is initialized (then you can deduce the table has an id), it's working, the other functionalities such as ColumnFixing is working, but the Resizing doesn't work.
Meanwhile, the following line:
gridDOM.find('table')
returns:
which is the element the igGrid is applied to, in the code of the previous post. So you can see the table has an id.
Here's the rest of the data used in the igGrid call, so you can reproduce the exact javascript enviroment:
gridDOM.find('table')<table id="ui-id-503"></table>
Performing more tests... this code works...
$('#ui-id-305').igGridResizing("resize", 1, 50);
so I verified the resizing is initialized at least, but anyawys, when I put the mouse cursor between two column headers, the pointer doesn't change and I'm not allowed to drag and drop it to change the columns size... so that's my problem.
We are currently looking into this matter and will keep you posted of any available information.Please do not hesitate to contact us with any updates or additional questions regarding this scenario in the meantime.