This is a migrated thread and some comments may be shown as answers.

Right to left column

1 Answer 92 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Tooraj
Top achievements
Rank 1
Tooraj asked on 08 May 2011, 08:44 AM
Hi,
I have a column named RequestNo which holds a text like this: 89-1-1
I have made my RadGridView RightToLeft and I set its font to some special font.
The column shows the specified value as 1-1-89 that is vice versa. this is natural because of RightToLeft property but this is not what I desire, I want my Grid Right To Left and show one column's content as if it were Left To Right!
I know that I can use REVERSE function of SQL Server in suppling data for the grid but I'm not sure it works well for filtering.
Is there anyway to make only one column Left To Right and leaving other columns Left To Right?
Thank you again,
Tooraj Azizi.

1 Answer, 1 is accepted

Sort by
0
Ivan Todorov
Telerik team
answered on 11 May 2011, 11:10 AM
Hello Tooraj,

Thank you for your question.

There is a way to make the column content Left to Right by using the CellFormatting event:
void radGridView1_CellFormatting(object sender, Telerik.WinControls.UI.CellFormattingEventArgs e)
        {
            if (e.Column.Name == "MyColumnName")
            {
                e.CellElement.RightToLeft = false;
            }
            else
            {
                e.CellElement.ResetValue(RadElement.RightToLeftProperty);
            }
        }

I hope this helps. If you have any additional questions, do not hesitate to ask.

Kind regards,
Ivan Todorov
the Telerik team
Q1’11 SP1 of RadControls for WinForms is available for download; also available is the Q2'11 Roadmap for Telerik Windows Forms controls.
Tags
GridView
Asked by
Tooraj
Top achievements
Rank 1
Answers by
Ivan Todorov
Telerik team
Share this question
or