Home Forums WinForms controls Xceed Grid for WinForms columnManagerRow.Cells Alignment

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • User (Old forums)
    Post count: 23064
    #15620 |


    I am trying to set different alignments for a columnManagerRow but it does not seem to set the alignment. Is there a way to set different alignments for the column headers. The following is the code I have tried.

    Dim columnManagerRow As ColumnManagerRow = New ColumnManagerRow

    columnManagerRow.Height = 30
    columnManagerRow.AllowColumnReorder = False

    columnManagerRow.Cells(9).HorizontalAlignment = HorizontalAlignment.Right
    columnManagerRow.Cells(10).HorizontalAlignment = HorizontalAlignment.Left



    Imported from legacy forums. Posted by Andrew (had 1916 views)

    Xceed Support
    Post count: 5658

    I tried reproducing the error and I was not able.

    I was able to change the alignment of the cells from the columnManagerRow with 2 different approachs.

    First, through the columnManagerRow that is created when you drop the gridControl on the Form:

    columnManagerRow1.Cells(5).HorizontalAlignment = Xceed.Grid.HorizontalAlignment.Right
    columnManagerRow1.Cells(4).HorizontalAlignment = Xceed.Grid.HorizontalAlignment.Left

    Second, through the FixedHeaderRows collection, the columnManagerRow being the second FixedHeaderRow:

    DirectCast(gridControl1.FixedHeaderRows(1), ColumnManagerRow).Cells(5).HorizontalAlignment = Xceed.Grid.HorizontalAlignment.Right
    DirectCast(gridControl1.FixedHeaderRows(1), ColumnManagerRow).Cells(4).HorizontalAlignment = Xceed.Grid.HorizontalAlignment.Left

    Imported from legacy forums. Posted by CharlesB (had 3176 views)

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.