I have created a grid which is to be displayed right-to-left. This grid has a pager item which should also be displayed right-to-left. Regardless of the 'dir' setting my numeric pager item is always displayed left-to-right (but right-aligned). I would like to know how to enforce RTL direction on the numeric pager item so that the numeric hyperlinks are displayed RTL.
I have created a simple page, shown below, which exhibits this behaviour.
Default.aspx:
Default.aspx.cs
The following demo: http://demos.telerik.com/aspnet-ajax/grid/examples/styles/righttoleft/defaultcs.aspx correctly displays the numeric pager hyperlinks right-to-left. I cannot see any obvious difference between my page and the Telerik demo.
I am using RadControls for ASP.NET AJAX Q3 2008.
Any help is greatly appreciated.
I have created a simple page, shown below, which exhibits this behaviour.
Default.aspx:
| <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> |
| <%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Web.UI" tagprefix="telerik" %> |
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
| <html xmlns="http://www.w3.org/1999/xhtml" dir="rtl"> |
| <head runat="server"> |
| <title>Numeric Pager RTL Test</title> |
| </head> |
| <body> |
| <form id="form1" runat="server"> |
| <div dir="rtl"> |
| <telerik:RadScriptManager ID="RadScriptManager1" Runat="server"/> |
| <telerik:RadGrid ID="RadGrid1" runat="server" PageSize="5" Skin="Vista" AllowPaging="True" ShowGroupPanel="True" Width="100%"> |
| <PagerStyle AlwaysVisible="True" Mode="NumericPages" PageButtonCount="5" /> |
| <MasterTableView CommandItemDisplay="Top" Dir="RTL"/> |
| </telerik:RadGrid> |
| </div> |
| </form> |
| </body> |
| </html> |
Default.aspx.cs
| using System; |
| using System.Data; |
| using System.Globalization; |
| public partial class _Default : System.Web.UI.Page |
| { |
| protected void Page_Load(object sender, EventArgs e) |
| { |
| System.Threading.Thread.CurrentThread.CurrentUICulture = new CultureInfo("ar-SA"); |
| DataSet ds = new DataSet("NumericPagerDataSet"); |
| DataTable dt = new DataTable("GridTable"); |
| dt.Columns.Add("Id", System.Type.GetType("System.String")); |
| ds.Tables.Add(dt); |
| for (int i = 0; i < 10; i++) |
| { |
| DataRow dr = dt.NewRow(); |
| dr.SetField("Id", i.ToString()); |
| dt.Rows.Add(dr); |
| } |
| RadGrid1.DataSource = ds; |
| RadGrid1.DataBind(); |
| } |
| } |
The following demo: http://demos.telerik.com/aspnet-ajax/grid/examples/styles/righttoleft/defaultcs.aspx correctly displays the numeric pager hyperlinks right-to-left. I cannot see any obvious difference between my page and the Telerik demo.
I am using RadControls for ASP.NET AJAX Q3 2008.
Any help is greatly appreciated.
