[CLOSED] Command Column alignment + header text not working

  1. #1

    [CLOSED] Command Column alignment + header text not working

    It appears that Command Columns in the gridpanel ignore the align and text attributes? For example, in the code below the column header text "Product Instance" doesn't appear and the image is left aligned:
    columnModel.Columns.Add(Html.X().CommandColumn()
                                   .Align(Alignment.Center)
                                   .Text("Product Instance")
                                   .Width(30)
                                   .Commands(commands => {
                                       commands.Add(Html.X().GridCommand()
                                           .Icon(Icon.Outline));
                                    }));
    If I use a standard column, the text/alignment seems correct... am I doing something wrong here or is this a bug?
    Last edited by Daniil; Apr 16, 2012 at 11:57 AM. Reason: [CLOSED]
  2. #2
    Hi,

    Aligning in cells is not supported with commands.

    I can suggest the following solution.

    Example
    <style type="text/css">
        .x-grid-cell-Column1 .cell-imagecommand-value {
            width: 77%;
        }
    </style>
    <ext:Column 
        ID="Column1" 
        runat="server" 
        Text="Test1" 
        DataIndex="test1" 
        Align="Center">
        <Commands>
            <ext:ImageCommand Icon="Accept" />
        </Commands>
    </ext:Column>
    Last edited by Daniil; Dec 25, 2014 at 5:21 PM.

Similar Threads

  1. Replies: 1
    Last Post: May 10, 2012, 9:50 PM
  2. [CLOSED] GridPanel Column Header Alignment
    By ArcadisUS in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Apr 08, 2011, 2:51 PM
  3. [CLOSED] Change text in header group column.
    By pdcase in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Mar 09, 2011, 3:44 PM
  4. [CLOSED] Column header text style
    By Stefanaccio in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Feb 03, 2011, 10:03 AM
  5. [CLOSED] Changind Column Header Text in AjaxRequest
    By amitpareek in forum 1.x Legacy Premium Help
    Replies: 11
    Last Post: Feb 02, 2010, 2:34 PM

Tags for this Thread

Posting Permissions