437
Views
11
Comments
Solved
[OutSystems Data Grid Web] Data Grid - Row Height
Question
outsystems-data-grid-web
Web icon
Forge asset by OutSystems

Hello

I am using the data grid component. I want to add some padding to the rows, to spread them out a bit, however need to make the rows larger. There is a row height input parameter on the component, however this does not seem to work for me?

Is there something I am missing?


Thanks

2018-10-15 13-43-39
Joseph Palmer
Solution

I eventually got this working using the extended CSS property. Thanks guys

2018-09-27 18-20-33
Swatantra Kumar
Champion

Check if the css class is being overridden?

2018-10-15 13-43-39
Joseph Palmer

Swatantra Kumar wrote:

Check if the css class is being overridden?

I can't see it anywhere in the css. Doesn't appear to be being overwritten


UserImage.jpg
Yoichi Hasegawa

Did you set the Row Height on GridContainer's Parameter?

I think it is working on DataGrid ver2.1.1.

I set the ExtendedClass on GridColumn's Parameter, I can set the padding with CSS.

2024-05-03 14-03-28
Sudip Dey

HI,

In the Datagrid, you need to add a CSS style as an extended CSS and override the CSS column height which uses the DataGrid row. I hope this will help you.

Thank you,

Sudip 

2018-10-15 13-43-39
Joseph Palmer
Solution

I eventually got this working using the extended CSS property. Thanks guys

2018-09-27 18-20-33
Swatantra Kumar
Champion

Great! That's what Sudip suggested in his answer.

2024-05-03 14-03-28
Sudip Dey

Swatantra Kumar wrote:

Great! That's what Sudip suggested in his answer.


Thank You @Swatantra Kumar

2020-07-13 18-35-41
Neil Gonzales

Can you show me how?

2020-08-05 09-00-16
Gabriel Lundgren

Hello Neil,


I've attached a sample where we change the row height parameter and it changes the height of the row. Please let me know if this helps you.

DataGridRowHeight.oml
2020-07-13 18-35-41
Neil Gonzales

Thanks! Got it. How about making it auto height? Would that be possible?

2020-08-05 09-00-16
Gabriel Lundgren

Hey Neil. Sorry about the delay.


You can set auto height by using autoRowHeights as true on Grid's AdvancedFormat property. 

For it to work, you need to set the RowHeight to 0. Bear in mind, that if your grid has many rows/columns, the performance will decrease a lot. So it's not recommended in this use case. 

I've attached a sample using autoRowHeights. But in my sample I have lots of rows, so the performance is not great.


Ps.: In the sample I set the second column to support multiLine property. To test it, edit the values and press alt + enter to create a new line.


In case you have any questions, feel free to ask us.


Thank you,

Gabriel Lundgren

DataGridRowHeightAutoSize.oml
Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.