Hi,
I need to read the grid header height in order to resize the panel that the grid is docked to. the header's Height property works fine when header text is not wrapped. However when header text is wrapped, the Height property is still the same as the single line case. How do i read the actual header height?
thanks.
Zongwen
Hello Zongwen,
I am not sure about which header you are talking about. If you mean the UltraGrid header, is seems that is a single line, if you are talking about the Column Headers, there is ColHeadersLines property which determines how many would be the column header lines, also there is a Band header which also has its own height.
You could get the actual header heights like:
ultraGrid1.DisplayLayout.Bands[Index].Columns[Key].Header.Height.ToString();
ultraGrid1.DisplayLayout.Bands[Index].Header.Height.ToString();
If that is not the case please provide me the code that you are using to set the header text and also please let me know what version of Infragistics components you are currently using.
Hi Danko,
The Columns[Key].Header.Height works now and reflect the actual column header heights. I was using Bands[Index].Header.Height which turned out to be always same for my case no matter whether the column header text are wrapped or not.
Thanks,
Bands[Index].Header.Height refers to the band header, which is not visible by default and does not include the column headers. :)