using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using Telerik.Web.UI;
using System.Data.OleDb;

public partial class _Default : System.Web.UI.Page
{

    protected void RadGri1_PreRender(object sender, EventArgs e)
    {       
               
    }

    protected void Button1_Click(object sender, EventArgs e)
    {
       

    }

    protected void Button1_Click1(object sender, EventArgs e)
    {
        RadGri1.AllowPaging = false;
        RadGri1.MasterTableView.Rebind();

        GridDataItem dataItem = (GridDataItem) RadGri1.MasterTableView.FindItemByKeyValue("OrderID", int.Parse(TextBox1.Text));
        int itemIndex, pageIndex;

        pageIndex = dataItem.ItemIndex / RadGri1.PageSize;
        itemIndex = dataItem.ItemIndex % pageIndex;

        RadGri1.AllowPaging = true;
        RadGri1.MasterTableView.CurrentPageIndex = pageIndex;
        RadGri1.MasterTableView.Rebind();

        RadGri1.MasterTableView.Items[itemIndex].Selected = true;
        RadGri1.MasterTableView.Items[itemIndex].Focus();

    }
}
