Hello everybody,
I cannot find a way to define the height of a row for an igGrid.
I would like to be able to set auto height for all row since some cells contain large text.
Is there a solution for this ?
thank's !
Hards
Hi Hards,
Auto height is the default behaviour in igGrid (which renders HTML table row elements). If you want fixed row height then look at this forum post:
http://es.infragistics.com/community/forums/t/69830.aspx
Hope this helps,Martin PavlovInfragistics, Inc.
Hello,
I don't have Auto height by default in my view , i don't understand, there is perhaps an error ...
Could you see after and say me what is the error in my developpement ?
Thanks
Best regards
<%= Html.Infragistics().Grid(Model.ListeDetailSuiviDossier).ID("list").AutoCommit(false).PrimaryKey("NUM_ETAPE").UpdateUrl(Url.Action("UpdatingSaveChanges")).AutoGenerateColumns(false).EnableHoverStyles(false)
.Columns(column =>
{ column.For(x => x.NUM_ETAPE).HeaderText("N°").Width("40");
column.For(x => x.NUM_DOSSIER).HeaderText("N°").Width("1");
column.For(x => x.DESCRIPTION).HeaderText("Description").Width("450"); //i have 500 characters for this field
column.For(x => x.REF_DOC).HeaderText("Ref_doc").Width("150");
column.For(x => x.DDEBUT).HeaderText("Date début").Width("100").Format("dd/MM/yyyy");
column.For(x => x.DFIN).HeaderText("Date fin").Width("100").Format("dd/MM/yyyy");
column.For(x => x.HORS_INDIC).HeaderText("Hors indicateur").Width("80");
})
.Features(features => {
features.Paging().Type(OpType.Local);
features.Sorting().Mode(SortingMode.Single).Type(OpType.Local);
features.Updating().EditMode(GridEditMode.Cell);
features.Updating().EnableAddRow(false).EnableDeleteRow(true).ColumnSettings(settings =>
{ settings.ColumnSetting().ColumnKey("HORS_INDIC")
.EditorType(ColumnEditorType.Combo)
.ComboEditorOptions(options => { options.DataSource(Model.ListHorsIndic); });
settings.ColumnSetting().ColumnKey("DDEBUT").EditorType(ColumnEditorType.DatePicker).EditorOptions("dateInputFormat : 'dateTime', DateDisplayFormat : 'dateTime', dateInputFormat : 'dd/MM/yyyy HH:mm'");
settings.ColumnSetting().ColumnKey("DFIN").EditorType(ColumnEditorType.DatePicker).EditorOptions("dateInputFormat : 'dateTime', DateDisplayFormat : 'dateTime', dateInputFormat : 'dd/MM/yyyy HH:mm'");
settings.ColumnSetting().ColumnKey("NUM_ETAPE").ReadOnly(true);
settings.ColumnSetting().ColumnKey("NUM_DOSSIER").ReadOnly(true);
});
.DataBind().Render()%>
and my view :
Hi Hardis,
I've setup a pure HTML web page which mimics your configuration(It's attached it to this forum post). You can see that the row height is auto adjustable depending on the content of the "Description" column. This behavior is by default which means that you don't need to explicitly set any igGrid option. igGrid renders TABLE element in the browser so the grid is following HTML specification for rendering a table element.
If in your page you're observing fixed row height then look at the page CSS rules. You may have defined fixed row height in CSS.
If you're talking about a multi-line editor for the "Description" column while editing a row, this currently cannot be achieved. That's because editors are INPUT elements with type="text" attribute.
Also I noticed that in your code you've defined "Updating" feature twice, but that shouldn't be a problem. The second definition will overwrite the first one.
Best regards,
Martin Pavlov
Infragistics, Inc.
Hello Hardis,
Please let us know if you need further assistance with this issue.
Glad to hear you found a solution. Please let us know if you need any further assistance with this and we'll be glad to help you.
We found the solution, the tests have done with characteres without space and in this case the line is trunked.
If you insert line with space then you can have several line in the cell...
Thank you