HighTechTalks DotNet Forums  

rquired help

ASP.net Building Controls microsoft.public.dotnet.framework.aspnet.buildingcontrols


Discuss rquired help in the ASP.net Building Controls forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
shuaib.is.khan@gmail.com
 
Posts: n/a

Default rquired help - 11-01-2007 , 07:46 AM






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


Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.