I am trying to get a default row height without setting it manually, so based on current font for example.
But when I check DefaultRowHeight off of the Override it's -1.
Does it have something to do with RowSizing enum? Currently it's set to AutoFree.
Hi Jiho,
A DefaultRowHeight of -1 means the grid calculates the height of each row based on a number of factors including the RowSizing property, the font, the existence of dropdown buttons in the row and possibly other factors.
So you can't simply get a single value for the DefaultRowHeight, since each row could be a different height.
If you want the height or any individual row, you can use the row's Height property.
I understand that it's calculated. When all my rows are of the same height, it's easy to get the row height by checking the very first row's Height property. But what if there are no rows?
By the way, my need for the height is for custom painting for drag and drop scenario. I need some kind of default height to draw a placeholder.