Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
3550
Align columns to right
posted

I am writing a new post, since I didnt get an answer for another thread.

http://es.infragistics.com/community/forums/t/67720.aspx

Since I use Hebrew,I need to right align the grid:

All headers to right.

All data to right.

 Pay attention, that header also need to be aligned to right, nont only data.

If possible, order of columns, Right to left.

How to do?

I have tried to add css, and it doesnt work.

Attached is a sample

Attachments_2012_07_5.zip
Parents
  • 29417
    Suggested Answer
    Offline posted

    Hello drpoalim,

     

    Since different styles get applied for the cells and for the headers you need to make sure that you define a different one for each.

    Here’s a link to our styling guide: http://es.infragistics.com/community/blogs/engineering/archive/2010/08/25/webdatagrid-css-styling-guide.aspx

     It contains in-depth information on the style sheets for the grid. 

    Generally most alignments are set to:

    text-align: left; 

    You’ll need to overwrite them with:

    text-align: right;

     

    Depending on which style set you use the class that you need to overwrite will be different but if you need this to be applied for all the grids you can use:

     

    For the cells:

    tbody > tr > td.Right

    {

        text-align: right;

    }

     

    For the headers:

     

    tbody > tr > th.HeaderRight

    {

        text-align: right;

    }

     

    Add these styles to the aspx page and set them to the BoundDataField CssClass and the Header CssClass. 

    Please refer to the attached sample and let me know if you have any questions or concerns.

     

    Best Regards,

    Maya Kirova

    Developer Support Engineer

    Infragistics, Inc.

    http://es.infragistics.com/support

     

    wdg_righToLeft.zip
Reply Children