ajjkiosd
ajjkiosd

Reputation: 11

Text Direction In DataGridView

I use telerik WinForms Components for my project

in RadGridView (Right to Left) :

https://i.sstatic.net/8j0Us.png

It Show 0001-9999 Instead of 9999-0001

How can i solve this?

Upvotes: 1

Views: 529

Answers (1)

Daniel
Daniel

Reputation: 5732

When I tried this on a WinForms RadGridView which has the RightToLeft property set to true, I did not see the number flipped like in your example.

RightToLeft Property for grid = true

However, you can set the RadGridView RightToLeft property to true, but change the RightToLeft property for one column in the CellFormatting event.

private void radGridView1_CellFormatting(object sender, Telerik.WinControls.UI.CellFormattingEventArgs e)
{
  if (e.CellElement.ColumnInfo.Name == "ID")
  {
    e.CellElement.RightToLeft = false;
  }
}

You can see the difference when the ID column cells have the RightToLeft property set to false.

RightToLeft Property for grid = true; cells in ID columns RightToLeft property set to false

Upvotes: 1

Related Questions