rquired help

S

shuaib.is.khan

i m craeting a custum control and implementing i call back event
handler in my control my code is this
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Text;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Drawing;

namespace WebControlLibrary2
{
[DefaultProperty("Text")]
[ToolboxData("<{0}:WebCustomControl1 runat=server></
{0}:WebCustomControl1>")]
public class WebCustomControl1 : DataGrid
{
public WebCustomControl1()
{
AllowPaging = true;
PageSize = 1;


}
protected override void
OnPageIndexChanged(DataGridPageChangedEventArgs e)
{
base.OnPageIndexChanged(e);

PagerStyle.Mode = PagerMode.NumericPages;
PagerStyle.BackColor = Color.Gainsboro;
PagerStyle.PageButtonCount = 10;
PagerStyle.HorizontalAlign = HorizontalAlign.Right;

// Default settings for pagination



// Other visual default settings
GridLines = GridLines.None;
CellSpacing = 2;
CellPadding = 2;
BorderColor = Color.Black;
BorderStyle = BorderStyle.Solid;
BorderWidth = (Unit)1;
ForeColor = Color.Black;
Font.Size = FontUnit.XSmall;
Font.Name = "Verdana";

// Settings for normal items (all or odd-only rows)
ItemStyle.BackColor = Color.Beige;

// Settings for alternating items (none or even-only rows)
AlternatingItemStyle.BackColor = Color.PaleGoldenrod;

// Settings for heading
HeaderStyle.Font.Bold = true;
HeaderStyle.BackColor = Color.Brown;
HeaderStyle.ForeColor = Color.White;
HeaderStyle.HorizontalAlign = HorizontalAlign.Center;

}





}
}
this work good but now i m want to implement icall back event hanler
insisde protected override void
OnPageIndexChanged(DataGridPageChangedEventArgs e)
{
}
i dont know how will be this done
please help me
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,535
Members
45,007
Latest member
obedient dusk

Latest Threads

Top