using System;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

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

public partial class Default : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }

    protected void RadGrid1_NeedDataSource(object source, Telerik.Web.UI.GridNeedDataSourceEventArgs e)
    {
        ArrayList list = new ArrayList();
        for (int i = 0; i < 100; i++)
        {
            list.Add(new TestListItem("Item " + i, i));
        }
        RadGrid1.DataSource = list;
        Label1.Text = "NeedDataSource fired at: " + DateTime.Now.ToString();
    }
    public class TestListItem
    {
        private string _a;
        private int? _b;
        public TestListItem(string a, int? b)
        {
            this._a = a;
            this._b = b;
        }
        public string A
        {
            get
            {
                return this._a;
            }
            set
            {
                this._a = value;
            }
        }
        public int? B
        {
            get
            {
                return this._b;
            }
        }
    }
}
