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

RadGridView RightToLeft Property

2 Answers 62 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Ibrahim
Top achievements
Rank 1
Ibrahim asked on 12 Jan 2011, 12:07 PM
When the RightToLeft property is set to Yes the right and left arrows behaves in wrong manner to move from column to another

2 Answers, 1 is accepted

Sort by
0
Richard Slade
Top achievements
Rank 2
answered on 12 Jan 2011, 12:30 PM
Hello,

I can confirm that I can replicate this in the latest version of the RadGridView.
Regards,
Richard
0
Stefan
Telerik team
answered on 14 Jan 2011, 11:09 AM
Hi Ibrahim,

Thank you for writing.

I am writing to confirm that this is an issue in RightToLeft mode in RadGridView. I have added this issue in our Public Issue Tracking System where you can check the status of the issue.

Meanwhile, you can override this behavior by creating a new custom GridBehavior where you can handle those keys. Please refer to the following code snippet, which demonstrates how can you create such a custom behavior:
class CustomBehavior : BaseGridBehavior
{
    public override bool ProcessKey(KeyEventArgs keys)
    {
        if (keys.KeyData == Keys.Left)
        {
            this.GridViewElement.Navigator.SelectNextColumn();
            return true;
        }
        else if (keys.KeyData == Keys.Right)
        {
            this.GridViewElement.Navigator.SelectPreviousColumn();
            return true;
        }
         return base.ProcessKey(keys);
    }
}

After that you just have to register the custom behavior for your RadGridView:
radGridView1.GridBehavior = new CustomBehavior();

Your Telerik points have been updated for this report.

I hope this information addresses your question. Let me know if you need anything else.

Best wishes,
Stefan
the Telerik team
Q3’10 SP1 of RadControls for WinForms is available for download; also available is the Q1'11 Roadmap for Telerik Windows Forms controls.
Tags
GridView
Asked by
Ibrahim
Top achievements
Rank 1
Answers by
Richard Slade
Top achievements
Rank 2
Stefan
Telerik team
Share this question
or