0

I have the following problem: on runtime I am changing the name of the columns caption (the grid is linked to a table and I don't want the user to see their original name). However I have one header caption which is too long - "Total Number of votes" which actually represents an integer not bigger than 4 digits. My question is how I can fix the header caption width ... in my case I want it to appear on two lines?

Andrey
  • 479
  • 2
  • 10
  • 20

2 Answers2

0

you can add property ItemStyle-Width="your value"

Example for bound field

<asp:BoundField DataField="" HeaderText="" ItemStyle-Width="150"/>
Aghilas Yakoub
  • 28,516
  • 5
  • 46
  • 51
0

If you want column caption to wrap set column HeaderStyle.Wrap to True.

<dxg:ASPxGridView runat="server">
    <Columns>
        <dxg:GridViewDataColumn FieldName="Test" VisibleIndex="1" >
            <HeaderStyle Wrap="True"/>
        </dxg:GridViewDataColumn>
    </Columns>
</dxg:ASPxGridView>
Filip
  • 3,257
  • 2
  • 22
  • 38